mirror of
https://github.com/dorny/paths-filter.git
synced 2025-06-08 10:01:34 +00:00
Fix lint findings
This commit is contained in:
parent
00461c6632
commit
19fa779d55
6 changed files with 34 additions and 28 deletions
|
@ -1,7 +1,7 @@
|
|||
import {describe, expect, test} from 'vitest'
|
||||
|
||||
import {Filter} from '../src/filter'
|
||||
import {File, ChangeStatus} from '../src/file'
|
||||
import {Filter} from '../src/filter'
|
||||
|
||||
describe('yaml filter parsing tests', () => {
|
||||
test('throws if yaml is not a dictionary', () => {
|
||||
|
@ -26,7 +26,7 @@ describe('matching tests', () => {
|
|||
const yaml = `
|
||||
src: "src/**/*.js"
|
||||
`
|
||||
let filter = new Filter(yaml)
|
||||
const filter = new Filter(yaml)
|
||||
const files = modified(['src/app/module/file.js'])
|
||||
const match = filter.match(files)
|
||||
expect(match.src).toEqual(files)
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
import {describe, expect, test} from 'vitest'
|
||||
|
||||
import * as git from '../src/git'
|
||||
import {ChangeStatus} from '../src/file'
|
||||
import * as git from '../src/git'
|
||||
|
||||
describe('parsing output of the git diff command', () => {
|
||||
test('parseGitDiffOutput returns files with correct change status', async () => {
|
||||
test('parseGitDiffOutput returns files with correct change status', () => {
|
||||
const files = git.parseGitDiffOutput(
|
||||
'A\u0000LICENSE\u0000' + 'M\u0000src/index.ts\u0000' + 'D\u0000src/main.ts\u0000'
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue