8000 Update packages/eslint-plugin/tests/rules/prefer-optional-chain.test.ts · omril1/typescript-eslint@7e2185e · GitHub
[go: up one dir, main page]

Skip to content

Commit 7e2185e

Browse files
omril1Josh-Cena
andauthored
Update packages/eslint-plugin/tests/rules/prefer-optional-chain.test.ts
Co-authored-by: Joshua Chen <sidachen2003@gmail.com>
1 parent a68b13a commit 7e2185e

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

packages/eslint-plugin/tests/rules/prefer-optional-chain.test.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -201,10 +201,10 @@ ruleTester.run('prefer-optional-chain', rule, {
201201
'!a.#foo || !a.#foo.bar;',
202202
'a.#foo?.bar;',
203203
'!a.#foo?.bar;',
204-
'foo().#a;',
205-
'a.b.#a;',
206-
'new A().#b;',
207-
'(await a).#b;',
204+
'!foo().#a || a;',
205+
'!a.b.#a || a;',
206+
'!new A().#b || a;',
207+
'!(await a).#b || a;',
208208
// currently do not handle complex computed properties
209209
'foo && foo[bar as string] && foo[bar as string].baz;',
210210
'foo && foo[1 + 2] && foo[1 + 2].baz;',

0 commit comments

Comments
 (0)
0