Skip to content

Commit

Permalink
Merge remote-tracking branch 'vue-mess-detector/main'
Browse files Browse the repository at this point in the history
  • Loading branch information
rrd108 committed Oct 1, 2024
2 parents 83660e5 + 9096827 commit c40490a
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions src/rules/rrd/nestedTernary.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,20 @@ describe('checkNestedTernary', () => {
expect(result).toStrictEqual([])
})

it.todo('should not report files with ts optional symbol', () => {
const script = {
content: `
type TestType = { value?: number; name?: string }
const temp: Array<TestType> = []
`,
} as SFCScriptBlock
const fileName = 'nestedTernary.vue'
checkNestedTernary(script, fileName)
const result = reportNestedTernary()
expect(result.length).toBe(0)
expect(result).toStrictEqual([])
})

it('should report files with nested ternary', () => {
const script = {
content: `const pass = 'Gauranga%)'
Expand Down

0 comments on commit c40490a

Please sign in to comment.