1
0
mirror of https://github.com/sasjs/lint.git synced 2026-01-18 17:50:05 +00:00

chore(*): separate tests for test and fix functions

This commit is contained in:
Krishna Acondy
2021-04-21 15:22:02 +01:00
parent 3da3e1e134
commit 2687a8fa46
3 changed files with 9 additions and 3 deletions

View File

@@ -2,7 +2,7 @@ import { LintConfig, Severity } from '../../types'
import { LineEndings } from '../../types/LineEndings'
import { lineEndings } from './lineEndings'
describe('lineEndings', () => {
describe('lineEndings - test', () => {
it('should return an empty array when the text contains the configured line endings', () => {
const text = "%put 'hello';\n%put 'world';\n"
const config = new LintConfig({ lineEndings: LineEndings.LF })
@@ -101,7 +101,9 @@ describe('lineEndings', () => {
severity: Severity.Warning
})
})
})
describe('lineEndings - fix', () => {
it('should transform line endings to LF', () => {
const text =
"%put 'hello';\r\n%put 'test';\r\n%put 'world';\n%put 'test2';\n%put 'world2';\r\n"