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

Support for Verify #2602

Merged
merged 10 commits into from
Aug 10, 2022
Merged

Support for Verify #2602

merged 10 commits into from
Aug 10, 2022

Conversation

SabotageAndi
Copy link
Contributor

Types of changes

  • Bug fix (non-breaking change which fixes an issue).
  • New feature (non-breaking change which adds functionality).
  • Breaking change (fix or feature that would cause existing functionality to not work as expected).
  • Performance improvement
  • Refactoring (so no functional change)
  • Other (docs, build config, etc)

Checklist:

  • I've added tests for my code. (most of the time mandatory)
  • I have added an entry to the changelog. (mandatory)
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.

@SabotageAndi
Copy link
Contributor Author

@Bayn Verify is working with this, but the naming of the files isn't right yet.

I think with https://github.com/VerifyTests/Verify/blob/main/docs/naming.md#derivepathinfo we could adjust the generation that it takes Feature title/Scenario title automatically.

Perhaps you can have a look at this?

@baynezy
Copy link

baynezy commented May 24, 2022

Thanks @SabotageAndi - I'll take a look later this week. I really appreciate your help.

@SimonCropp
Copy link

shouldnt specflow default to duplicating all attributes from *StepDefinitions over to *.feature.cs ?

@SimonCropp
Copy link

@SabotageAndi as a workaround. you can add a partial with the marker attribute to your project

namespace Example.Spec.Features;

[UsesVerify]
public partial class HtmlGenerationFeature
{
}

note you will need one per definition and the namespace and name have to match

@SabotageAndi
Copy link
Contributor Author

shouldnt specflow default to duplicating all attributes from *StepDefinitions over to *.feature.cs ?

No, it doesn't. The Step definitions are executed at runtime. Some Gherkin tags (@some_tag) are translated to attributes, but not all.

@kaylumah
Copy link

kaylumah commented Aug 7, 2022

@SabotageAndi this looks very promesing, any plans on officially releasing this plugin?

@SabotageAndi SabotageAndi marked this pull request as ready for review August 10, 2022 15:06
@SabotageAndi SabotageAndi merged commit a64b51e into master Aug 10, 2022
Code-Grump pushed a commit to Code-Grump/SpecFlow that referenced this pull request Mar 29, 2023
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

Successfully merging this pull request may close these issues.

4 participants