-
Notifications
You must be signed in to change notification settings - Fork 164
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
Some Examples were not recognized #343
Conversation
return c.Resolve<MarkdownProvider>(); | ||
} | ||
}).SingleInstance(); | ||
builder.Register( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A request for the future: try not to give in to resharper's temptation to optimize code that is unrelated to the feature you're working on. I know it's difficult :-)
I won't reject the PR because of this but please keep it in mind for the future.
Ok, sorry for that |
Thanks again for your hard work over the last few days! |
Released as version 2.6.2 |
No problem, I use this currently in production, and I'm happy to help if I find something. It's also a fun side project |
var name = SpecFlowNameMapping.Build(scenarioOutline.Name.ToLowerInvariant()); | ||
stringBuilder.Append(name).Append("\\("); | ||
|
||
foreach (var value in row.Select(v => v.Length > MaxExampleValueLength ? new { Value = v.Substring(0, MaxExampleValueLength), Ellipsis = "..." } : new { Value = v, Ellipsis = "" })) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@magicmonty and @dirkrombauts ... can you provide a bit more explanation why we need to limit the "signature" for searching examples in NUnit3 to 37 characters? This has kept some of the tests in our environment from showing Pass / Fail on the generated Pickles site. If I simply remove the logic to trim these signatures and allow for the full length, it works fine.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm afraid I don't remember why it had to be 37 characters ... @magicmonty do you remember?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I remember correctly, then the output in the result XML is was truncated by 37 characters (at least at the time of writing) (see https://github.com/picklesdoc/pickles/blob/develop/src/Pickles/Pickles.TestFrameworks.UnitTests/NUnit/NUnit3/results-example-nunit3.xml#L574)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@magicmonty - thanks!
@ocsurfnut - you say if you remove the logic to trim, it works fine. Do you mean that it works on your feature files, or do you mean that the unit tests in Pickles pass?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dirkrombauts I didn't run the unit tests (yet). It "works fine" in that the generated Pickles site has the test results correlated correctly for these examples. Otherwise, with the trimming, the scenario shows as Inconclusive.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
NUnit 3.6 does no longer truncate long results. @ocsurfnut thanks for bringing this to my attention. I will publish a new version soon.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you @dirkrombauts , pls tag me on your revision when you get around to it. Thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ocsurfnut I released a fix for the Nunit 3 problem in version 2.13.0.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dirkrombauts , thank you for the patch! I've implemented 2.13.0 on our pipeline and that resolved the issue.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ocsurfnut glad to hear it!
Examples are not recognized on some test frameworks if the examples are too long