-
Notifications
You must be signed in to change notification settings - Fork 584
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
Debugging ng test doesn't work #9
Comments
From @chrmarti on June 27, 2017 20:45 Same here on Windows. |
The test setup ( |
Was looking at this with @Lixire, and I couldn't even get sourcemaps loaded in chrome devtools. |
@weinand I noticed recently that the source maps are an issue again -- this time with |
@tonysneed I don't think it's just a source map issue. |
@weinand I don't think the approach has changed in a way that can't be documented in the recipe. ng test still uses Karma like before, and the window that pops up has a debug button on it, which brings up the same url as specified in the test confit in launch.json. So if the source map issue is resolved, we should be back on track with debugging tests with the chrome debugger extension for vs code. Can we get some input from someone on the A-CLI and/or the debugger extension teams? |
I can look into it later but I don't have time this week. |
Running
Looks like there's some magic bundeling going on now in |
Downgrading to angular-cli 1.1.1 resolves the issue. Seems to validate this reported issue in |
That issue sounds very relevant :D |
@auchenberg thanks for investigating this and finding angular/angular-cli#6824. |
first off thank you so much for your work, and your time. Can you please add steps to debug e2e tests, using protractor and the CLI |
@tonysneed thanks a lot |
@tonysneed @weinand just for learning purpose, whey running npm start vs. ng start ? if you have the same version of the CLI locally and globally it should be OK to go with ng start ? |
@daBishMan So the issue arises when you update the global CLI package. If you run So it's much better to use Also you can pass args to the npm command. For example to open the browser:
|
@tonysneed thank you :) |
@weinand @daBishMan Happy to help! 😄 |
@tonysneed thank you so much for your help with this. When I try to debug e2e tests I get the error below. Yes, the breakpoint gets hit in VS Code, but the test fails. Anyone else experiencing this? You can check it out via this repo https://github.com/daBishMan/biz-app
|
@daBishMan I just clone your repo and ran
|
@auchenberg thanks again very much for your help yes, it does work now; really appreciate your time :) |
I have a related issue so I'll just ask here instead of creating another issue. The debugging works for me in such way, that when I'm stepping forward, nothing happens in the browser. Only after I step out of the it blocks, the commands actually run in the browser. Is this the desired behavior? When running e2e tests in Ruby I could step forward and see what the browser is actually doing each step (so I could inspect the DOM state etc.) |
From @jrieken on June 27, 2017 8:43
testing #29476
The last step which is about debugging test doesn't work for me. Breakpoints appear as empty circles not discs.
Copied from original issue: microsoft/vscode#29539
The text was updated successfully, but these errors were encountered: