1
0
mirror of https://github.com/sasjs/lint.git synced 2026-01-17 09:10:06 +00:00

chore: removed redundant property from parsedMacros

This commit is contained in:
Saad Jutt
2021-05-20 23:00:59 +05:00
parent d7721f8e5e
commit 8bfb547427
2 changed files with 0 additions and 11 deletions

View File

@@ -20,7 +20,6 @@ describe('parseMacros', () => {
endLineNumber: 3, endLineNumber: 3,
parentMacro: '', parentMacro: '',
hasMacroNameInMend: false, hasMacroNameInMend: false,
hasParentheses: false,
mismatchedMendMacroName: '' mismatchedMendMacroName: ''
}) })
}) })
@@ -43,7 +42,6 @@ describe('parseMacros', () => {
endLineNumber: 3, endLineNumber: 3,
parentMacro: '', parentMacro: '',
hasMacroNameInMend: false, hasMacroNameInMend: false,
hasParentheses: false,
mismatchedMendMacroName: '' mismatchedMendMacroName: ''
}) })
}) })
@@ -66,7 +64,6 @@ describe('parseMacros', () => {
endLineNumber: 3, endLineNumber: 3,
parentMacro: '', parentMacro: '',
hasMacroNameInMend: false, hasMacroNameInMend: false,
hasParentheses: false,
mismatchedMendMacroName: '' mismatchedMendMacroName: ''
}) })
}) })
@@ -90,7 +87,6 @@ describe('parseMacros', () => {
endLineNumber: 4, endLineNumber: 4,
parentMacro: '', parentMacro: '',
hasMacroNameInMend: false, hasMacroNameInMend: false,
hasParentheses: false,
mismatchedMendMacroName: '' mismatchedMendMacroName: ''
}) })
}) })
@@ -116,7 +112,6 @@ describe('parseMacros', () => {
endLineNumber: 3, endLineNumber: 3,
parentMacro: '', parentMacro: '',
hasMacroNameInMend: false, hasMacroNameInMend: false,
hasParentheses: false,
mismatchedMendMacroName: '' mismatchedMendMacroName: ''
}) })
expect(macros).toContainEqual({ expect(macros).toContainEqual({
@@ -129,7 +124,6 @@ describe('parseMacros', () => {
endLineNumber: 6, endLineNumber: 6,
parentMacro: '', parentMacro: '',
hasMacroNameInMend: true, hasMacroNameInMend: true,
hasParentheses: true,
mismatchedMendMacroName: '' mismatchedMendMacroName: ''
}) })
}) })
@@ -155,7 +149,6 @@ describe('parseMacros', () => {
endLineNumber: 6, endLineNumber: 6,
parentMacro: '', parentMacro: '',
hasMacroNameInMend: true, hasMacroNameInMend: true,
hasParentheses: true,
mismatchedMendMacroName: '' mismatchedMendMacroName: ''
}) })
expect(macros).toContainEqual({ expect(macros).toContainEqual({
@@ -168,7 +161,6 @@ describe('parseMacros', () => {
endLineNumber: 5, endLineNumber: 5,
parentMacro: 'test', parentMacro: 'test',
hasMacroNameInMend: false, hasMacroNameInMend: false,
hasParentheses: false,
mismatchedMendMacroName: '' mismatchedMendMacroName: ''
}) })
}) })

View File

@@ -12,7 +12,6 @@ interface Macro {
termination: string termination: string
parentMacro: string parentMacro: string
hasMacroNameInMend: boolean hasMacroNameInMend: boolean
hasParentheses: boolean
mismatchedMendMacroName: string mismatchedMendMacroName: string
} }
@@ -52,7 +51,6 @@ export const parseMacros = (text: string, config?: LintConfig): Macro[] => {
parentMacro: macroStack.length parentMacro: macroStack.length
? macroStack[macroStack.length - 1].name ? macroStack[macroStack.length - 1].name
: '', : '',
hasParentheses: trimmedStatement.endsWith('()'),
hasMacroNameInMend: false, hasMacroNameInMend: false,
mismatchedMendMacroName: '', mismatchedMendMacroName: '',
declarationLine: line, declarationLine: line,
@@ -79,7 +77,6 @@ export const parseMacros = (text: string, config?: LintConfig): Macro[] => {
startLineNumber: null, startLineNumber: null,
endLineNumber: index + 1, endLineNumber: index + 1,
parentMacro: '', parentMacro: '',
hasParentheses: false,
hasMacroNameInMend: false, hasMacroNameInMend: false,
mismatchedMendMacroName: '', mismatchedMendMacroName: '',
declarationLine: '', declarationLine: '',