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

Feat: Support place breakpoint from specflow file #2

Closed
Socolin opened this issue Jan 24, 2021 · 6 comments
Closed

Feat: Support place breakpoint from specflow file #2

Socolin opened this issue Jan 24, 2021 · 6 comments
Assignees
Labels
enhancement New feature or request

Comments

@Socolin
Copy link
Collaborator

Socolin commented Jan 24, 2021

Place a breakpoint should allow to during scenario

Step into should go to the step declaration
Step over should go to the next step

@Socolin Socolin self-assigned this Jan 24, 2021
@Socolin Socolin added the enhancement New feature or request label Jan 24, 2021
@kotelni
Copy link

kotelni commented Feb 20, 2021

It is really a basic feature, needed often. If you have a step which is called multiple times with different parameters from the same feature file, then you cannot really put a breakpoint in the step itself (in C#), because it will be called from multiple places of the feature file.

@Socolin Socolin removed their assignment Mar 9, 2021
@Socolin
Copy link
Collaborator Author

Socolin commented Mar 17, 2021

A first version is available here, but I need to figure out why the lines highlighted during debug are bigger than the steps

https://github.com/SpecFlowOSS/SpecFlow.Rider/tree/breakpoint-featurefile

BugDebugHighlightTooLarge

@Socolin Socolin self-assigned this Mar 17, 2021
@nemesv
Copy link
Contributor

nemesv commented Mar 26, 2021

Included in version 1.4.0

@nemesv nemesv closed this as completed Mar 26, 2021
@kotelni
Copy link

kotelni commented Apr 20, 2021

Yes, a breakpoint can now be placed and the debugger will stop there. BUT the next logical step for the developer is to step-into the line (F11). This does not work properly. It either goes to the auxiliary classes (not interesting to anybody, like StepRunner), or if the Setting is "Enable External Code Debug" is off, it does not go into at all, i.e. goes to the next line on the feature file (as if I pressed F10).

It should go directly to the bound method in .cs file with steps implementation.

Actually, this was requested in the original comment by Socolin:
"Step into should go to the step declaration"
It is not implemented :-)

@Socolin
Copy link
Collaborator Author

Socolin commented Apr 21, 2021

Hello,

We don't have control over the debugger part so it's a bit tricky, so far it's possible to achieve this with one more click on this icon:
image

  • Place a breakpoint on the steps
  • When the breakpoint trigger, use "Go to declaration" shortcut, then click the button

Here an example:

ExampleDebugerGoToStep

If you think this is not good enough, please open another issue to track this, and I'll ask to the jetbrains team if it would be possible to hooks the "Step into" or find another workaround :)

@kotelni
Copy link

kotelni commented Apr 21, 2021

Thanks, Socolin for suggested workaround. I will try and see if it is good enough.

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

No branches or pull requests

3 participants