Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Doesn't support some TypeScript syntax #4

Closed
svekl opened this issue Sep 1, 2021 · 9 comments
Closed

Doesn't support some TypeScript syntax #4

svekl opened this issue Sep 1, 2021 · 9 comments

Comments

@svekl
Copy link

svekl commented Sep 1, 2021

Extension doesn't start after updating to v0.1.0
image

Couldn't find any additional details in output channels

@smarschollek
Copy link
Owner

smarschollek commented Sep 1, 2021

mh i tried every way - did an update from every prior version to 0.1.0 but i can not reproduce it.
Also askey my colleagues if there had a similar issue.

Just to be sure complete uninstall/reinstall did not help ?

@svekl
Copy link
Author

svekl commented Sep 2, 2021

Yeah, looks like that, just tried:

  1. Uninstalled both test explorer and adapter
  2. Restart vscode
  3. Install both extensions
  4. Restart vscode

And result is the same

Just in case, here is vscode version from about window:
Version: 1.59.1 (Universal)
Commit: 3866c3553be8b268c8a7f8c0482c0c0177aa8bfa
Date: 2021-08-19T11:53:52.479Z
Electron: 13.1.7
Chrome: 91.0.4472.124
Node.js: 14.16.0
V8: 9.1.269.36-electron.0
OS: Darwin x64 20.5.0

Can I get some more additional info for you somewhere?

@svekl
Copy link
Author

svekl commented Sep 2, 2021

Just found reactScriptsTestAdapter.logpanel setting, enabled and got

[2021-09-02 14:37:06.157] [INFO] Creating adapter for /Users/svekl/projects/[redacted]
[2021-09-02 14:37:06.158] [INFO] Initializing react-scripts test adapter
[2021-09-02 14:37:06.158] [INFO] Registering adapter for /Users/svekl/projects/[redacted]
[2021-09-02 14:37:06.158] [INFO] Loading tests...
[2021-09-02 14:37:06.158] [INFO] Initialization finished

looks healthy 🤔

@smarschollek
Copy link
Owner

Okay thanks - i will take a look 👍

@svekl
Copy link
Author

svekl commented Sep 2, 2021

@smarschollek just opened another repo and can see tests and run them, so it's something on this exact project

@svekl
Copy link
Author

svekl commented Sep 2, 2021

Ran extension in debug mode from vscode and there is some output in Debug console

(node:87079) [DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead.
(Use `Code Helper (Renderer) --trace-deprecation ...` to show where the warning was created)
failed to extract name for type "MemberExpression" in node: Node {type: 'ExpressionStatement', start: 1065, end: 1359, loc: SourceLocation, range: undefined, …}
failed to extract name for type "MemberExpression" in node: Node {type: 'ExpressionStatement', start: 1363, end: 1886, loc: SourceLocation, range: undefined, …}
failed to extract name for type "MemberExpression" in node: Node {type: 'ExpressionStatement', start: 1126, end: 1557, loc: SourceLocation, range: undefined, …}
failed to extract name for type "MemberExpression" in node: Node {type: 'ExpressionStatement', start: 1561, end: 2037, loc: SourceLocation, range: undefined, …}
failed to extract name for type "MemberExpression" in node: Node {type: 'ExpressionStatement', start: 2041, end: 2593, loc: SourceLocation, range: undefined, …}
failed to extract name for type "MemberExpression" in node: Node {type: 'ExpressionStatement', start: 2597, end: 3130, loc: SourceLocation, range: undefined, …}
failed to extract name for type "MemberExpression" in node: Node {type: 'ExpressionStatement', start: 1139, end: 1459, loc: SourceLocation, range: undefined, …}
failed to extract name for type "MemberExpression" in node: Node {type: 'ExpressionStatement', start: 1463, end: 1791, loc: SourceLocation, range: undefined, …}
failed to extract name for type "MemberExpression" in node: Node {type: 'ExpressionStatement', start: 1795, end: 2151, loc: SourceLocation, range: undefined, …}
failed to extract name for type "MemberExpression" in node: Node {type: 'ExpressionStatement', start: 1065, end: 1359, loc: SourceLocation, range: undefined, …}
failed to extract name for type "MemberExpression" in node: Node {type: 'ExpressionStatement', start: 1363, end: 1886, loc: SourceLocation, range: undefined, …}
failed to extract name for type "MemberExpression" in node: Node {type: 'ExpressionStatement', start: 1126, end: 1557, loc: SourceLocation, range: undefined, …}
failed to extract name for type "MemberExpression" in node: Node {type: 'ExpressionStatement', start: 1561, end: 2037, loc: SourceLocation, range: undefined, …}
failed to extract name for type "MemberExpression" in node: Node {type: 'ExpressionStatement', start: 2041, end: 2593, loc: SourceLocation, range: undefined, …}
failed to extract name for type "MemberExpression" in node: Node {type: 'ExpressionStatement', start: 2597, end: 3130, loc: SourceLocation, range: undefined, …}
failed to extract name for type "MemberExpression" in node: Node {type: 'ExpressionStatement', start: 1139, end: 1459, loc: SourceLocation, range: undefined, …}
failed to extract name for type "MemberExpression" in node: Node {type: 'ExpressionStatement', start: 1463, end: 1791, loc: SourceLocation, range: undefined, …}
failed to extract name for type "MemberExpression" in node: Node {type: 'ExpressionStatement', start: 1795, end: 2151, loc: SourceLocation, range: undefined, …}
rejected promise not handled within 1 second: SyntaxError: Unexpected token, expected "}" (782:25)
stack trace: SyntaxError: Unexpected token, expected "}" (782:25)
	at Object._raise (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:807:17)
	at Object.raiseWithData (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:800:17)
	at Object.raise (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:761:17)
	at Object.unexpected (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:9931:16)
	at Object.expect (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:9905:28)
	at Object.jsxParseExpressionContainer (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:5070:10)
	at Object.jsxParseElementAt (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:5161:36)
	at Object.jsxParseElement (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:5204:17)
	at Object.parseExprAtom (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:5211:19)
	at Object.parseExprSubscripts (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10904:23)
	at Object.parseUpdate (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10884:21)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10862:23)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7593:20)
	at Object.parseExprOps (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10719:23)
	at Object.parseMaybeConditional (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10693:23)
	at Object.parseMaybeAssign (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10656:21)
	at /Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7524:39
	at Object.tryParse (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:9958:20)
	at Object.parseMaybeAssign (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7524:18)
	at /Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10623:39
	at Object.allowInAnd (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:12310:12)
	at Object.parseMaybeAssignAllowIn (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10623:17)
	at Object.parseObjectProperty (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11854:101)
	at Object.parseObjectProperty (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:1049:24)
	at Object.parseObjPropValue (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11879:100)
	at Object.parseObjPropValue (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7483:11)
	at Object.parsePropertyDefinition (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11803:10)
	at Object.parseObjectLike (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11693:25)
	at Object.parseExprAtom (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11249:23)
	at Object.parseExprAtom (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:948:22)
	at Object.parseExprAtom (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:5216:20)
	at Object.parseExprSubscripts (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10904:23)
	at Object.parseUpdate (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10884:21)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10862:23)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7593:20)
	at Object.parseExprOps (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10719:23)
	at Object.parseMaybeConditional (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10693:23)
	at Object.parseMaybeAssign (/Users/svekl/projects…adapter/node_modules/@babel/parser/lib/index.js:11879:100)
	at Object.parseObjPropValue (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7483:11)
	at Object.parsePropertyDefinition (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11803:10)
	at Object.parseObjectLike (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11693:25)
	at Object.parseExprAtom (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11249:23)
	at Object.parseExprAtom (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:948:22)
	at Object.parseExprAtom (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:5216:20)
	at Object.parseExprSubscripts (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10904:23)
	at Object.parseUpdate (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10884:21)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10862:23)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7593:20)
	at Object.parseExprOps (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10719:23)
	at Object.parseMaybeConditional (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10693:23)
	at Object.parseMaybeAssign (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10656:21)
	at Object.parseMaybeAssign (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7538:20)
	at /Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10623:39
	at Object.allowInAnd (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:12310:12)
	at Object.parseMaybeAssignAllowIn (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10623:17)
	at Object.parseExprListItem (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:12070:18)
	at Object.parseCallExpressionArguments (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11102:22)
	at Object.parseCoverCallAndAsyncArrowHead (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11012:29)
	at Object.parseSubscript (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10948:19)
	at Object.parseSubscript (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:1121:24)
	at Object.parseSubscript (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7099:18)
	at Object.parseSubscripts (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10921:19)
	at Object.parseExprSubscripts (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10910:17)
	at Object.parseUpdate (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10884:21)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10862:23)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7593:20)
	at Object.parseAwait (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:12180:28)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10821:25)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7593:20)
	at Object.parseExprOps (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10719:23)
	at Object.parseMaybeConditional (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10693:23)
	at Object.parseMaybeAssign (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10656:21)
	at Object.parseMaybeAssign (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7538:20)
	at Object.parseExpressionBase (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10601:23)
	at /Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10595:39…
rejected promise not handled within 1 second: SyntaxError: Unexpected token, expected "}" (782:25)
stack trace: SyntaxError: Unexpected token, expected "}" (782:25)
	at Object._raise (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:807:17)
	at Object.raiseWithData (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:800:17)
	at Object.raise (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:761:17)
	at Object.unexpected (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:9931:16)
	at Object.expect (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:9905:28)
	at Object.jsxParseExpressionContainer (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:5070:10)
	at Object.jsxParseElementAt (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:5161:36)
	at Object.jsxParseElement (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:5204:17)
	at Object.parseExprAtom (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:5211:19)
	at Object.parseExprSubscripts (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10904:23)
	at Object.parseUpdate (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10884:21)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10862:23)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7593:20)
	at Object.parseExprOps (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10719:23)
	at Object.parseMaybeConditional (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10693:23)
	at Object.parseMaybeAssign (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10656:21)
	at /Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7524:39
	at Object.tryParse (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:9958:20)
	at Object.parseMaybeAssign (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7524:18)
	at /Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10623:39
	at Object.allowInAnd (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:12310:12)
	at Object.parseMaybeAssignAllowIn (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10623:17)
	at Object.parseObjectProperty (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11854:101)
	at Object.parseObjectProperty (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:1049:24)
	at Object.parseObjPropValue (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11879:100)
	at Object.parseObjPropValue (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7483:11)
	at Object.parsePropertyDefinition (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11803:10)
	at Object.parseObjectLike (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11693:25)
	at Object.parseExprAtom (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11249:23)
	at Object.parseExprAtom (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:948:22)
	at Object.parseExprAtom (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:5216:20)
	at Object.parseExprSubscripts (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10904:23)
	at Object.parseUpdate (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10884:21)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10862:23)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7593:20)
	at Object.parseExprOps (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10719:23)
	at Object.parseMaybeConditional (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10693:23)
	at Object.parseMaybeAssign (/Users/svekl/projects…adapter/node_modules/@babel/parser/lib/index.js:11879:100)
	at Object.parseObjPropValue (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7483:11)
	at Object.parsePropertyDefinition (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11803:10)
	at Object.parseObjectLike (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11693:25)
	at Object.parseExprAtom (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11249:23)
	at Object.parseExprAtom (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:948:22)
	at Object.parseExprAtom (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:5216:20)
	at Object.parseExprSubscripts (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10904:23)
	at Object.parseUpdate (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10884:21)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10862:23)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7593:20)
	at Object.parseExprOps (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10719:23)
	at Object.parseMaybeConditional (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10693:23)
	at Object.parseMaybeAssign (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10656:21)
	at Object.parseMaybeAssign (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7538:20)
	at /Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10623:39
	at Object.allowInAnd (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:12310:12)
	at Object.parseMaybeAssignAllowIn (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10623:17)
	at Object.parseExprListItem (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:12070:18)
	at Object.parseCallExpressionArguments (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11102:22)
	at Object.parseCoverCallAndAsyncArrowHead (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:11012:29)
	at Object.parseSubscript (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10948:19)
	at Object.parseSubscript (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:1121:24)
	at Object.parseSubscript (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7099:18)
	at Object.parseSubscripts (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10921:19)
	at Object.parseExprSubscripts (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10910:17)
	at Object.parseUpdate (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10884:21)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10862:23)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7593:20)
	at Object.parseAwait (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:12180:28)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10821:25)
	at Object.parseMaybeUnary (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7593:20)
	at Object.parseExprOps (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10719:23)
	at Object.parseMaybeConditional (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10693:23)
	at Object.parseMaybeAssign (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10656:21)
	at Object.parseMaybeAssign (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:7538:20)
	at Object.parseExpressionBase (/Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10601:23)
	at /Users/svekl/projects/vscode-react-scripts-test-adapter/node_modules/@babel/parser/lib/index.js:10595:39…

@svekl
Copy link
Author

svekl commented Sep 2, 2021

@smarschollek it fails on

const node = parse(file.fsPath)

in just one of my test files, I deleted this file and it works, so it's jest-editor-support fails on some TypeScript syntax

@svekl
Copy link
Author

svekl commented Sep 2, 2021

ok, so here is the issue:
in TypeScript you can cast type as

{} as SomeType

but also as

<SomeType>{}

and it fails on <SomeType>{} syntax in .test.ts file, just changing it to {} as SomeType fixes everything

it's completely unrelated to new extension version, it's just a weird coincidence that I wrote this code and restarted vscode same day

so issue comes from using parse from jest-editor-support, could it be related to jest-community/jest-editor-support#51 ?

not sure if it's possible to do something about it in this extension, but might make sense to add some try/catch and additional logging for easier tracking parsing errors? also could be nice if it could continue working for other files

@svekl svekl changed the title Extension doesn't start after v0.1.0 update Doesn't support some TypeScript syntax Sep 2, 2021
@smarschollek
Copy link
Owner

good news svekl i updated jest-editor-support and the problem is gone

image

so i will close the issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants