mirror of
https://github.com/sasjs/lint.git
synced 2026-01-07 12:40:05 +00:00
chore: specs fix
This commit is contained in:
@@ -32,16 +32,8 @@ describe('formatFile', () => {
|
|||||||
const expectedContent = `/**\r\n @file\r\n @brief <Your brief here>\r\n <h4> SAS Macros </h4>\r\n**/\r\n%macro somemacro();\r\n%put 'hello';\r\n%mend;`
|
const expectedContent = `/**\r\n @file\r\n @brief <Your brief here>\r\n <h4> SAS Macros </h4>\r\n**/\r\n%macro somemacro();\r\n%put 'hello';\r\n%mend;`
|
||||||
const expectedResult = {
|
const expectedResult = {
|
||||||
updatedFilePaths: [path.join(__dirname, 'format-file-config.sas')],
|
updatedFilePaths: [path.join(__dirname, 'format-file-config.sas')],
|
||||||
fixedDiagnosticsCount: 2,
|
fixedDiagnosticsCount: 4,
|
||||||
unfixedDiagnostics: [
|
unfixedDiagnostics: []
|
||||||
{
|
|
||||||
endColumnNumber: 7,
|
|
||||||
lineNumber: 8,
|
|
||||||
message: '%mend statement is missing macro name - somemacro',
|
|
||||||
severity: 1,
|
|
||||||
startColumnNumber: 1
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
}
|
||||||
await createFile(path.join(__dirname, 'format-file-config.sas'), content)
|
await createFile(path.join(__dirname, 'format-file-config.sas'), content)
|
||||||
|
|
||||||
|
|||||||
@@ -2,8 +2,8 @@ import * as fileModule from '@sasjs/utils/file'
|
|||||||
import { LintConfig } from '../types/LintConfig'
|
import { LintConfig } from '../types/LintConfig'
|
||||||
import { getLintConfig } from './getLintConfig'
|
import { getLintConfig } from './getLintConfig'
|
||||||
|
|
||||||
const expectedFileLintRulesCount = 5
|
const expectedFileLintRulesCount = 6
|
||||||
const expectedLineLintRulesCount = 5
|
const expectedLineLintRulesCount = 6
|
||||||
const expectedPathLintRulesCount = 2
|
const expectedPathLintRulesCount = 2
|
||||||
|
|
||||||
describe('getLintConfig', () => {
|
describe('getLintConfig', () => {
|
||||||
|
|||||||
Reference in New Issue
Block a user