Skip to content

Commit 5e0bc7a

Browse files
committed
make test happy
1 parent cea2bb9 commit 5e0bc7a

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

typescript/src/completions/isGoodPositionMethodCompletion.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ export const isGoodPositionBuiltinMethodCompletion = (ts: typeof tslib, sourceFi
1111
// const obj = { method() {}, arrow: () => {} }
1212
// type A = typeof obj["|"]
1313
if (ts.isStringLiteralLike(currentNode)) return false
14+
if (ts.isNamedExports(currentNode)) return false
1415
if (ts.isIdentifier(currentNode)) currentNode = currentNode.parent
1516
if (ts.isExportSpecifier(currentNode)) return false
1617
if (ts.isJsxSelfClosingElement(currentNode) || ts.isJsxOpeningElement(currentNode)) return false

typescript/test/completions.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,9 +115,9 @@ test('Banned positions', () => {
115115
test('Banned positions for all method snippets', () => {
116116
const cursorPositions = newFileContents(/* tsx */ `
117117
import {/*|*/} from 'test'
118-
export {/*|*/} from 'test'
119118
const obj = { m$1e$2thod() {}, arrow: () => {} }
120119
type A = typeof obj["/*|*/"];
120+
export {/*|*/} from 'test'
121121
a(({ a/*|*/ }) => {})
122122
const test = () => ({ method() {} })
123123
const {/*|*/} = test()

0 commit comments

Comments
 (0)