You can clone with
HTTPS or Subversion.
as was discussed at mailing list (https://groups.google.com/d/topic/cukes/4mYe8Tpb5Bs/discussion) cucumber has bug with Senario|ScenarioOutline.name (which is declared in Cucumber::Ast::Names (https://github.com/cucumber/cucumber/blob/master/lib/cucumber/ast/names.rb)).
If we have scenario:
And having before hook:
Before do |scenario|
The hook prints name as "line1.\nline2." While scenario name must be one line string.
I've just taken a quick look at this.
The Names module is included in the following classes.
Currently each of these classes has a @title and @description, and including Names adds readers for those, plus a #name method, which concats them.
Does gherkin define them as name and description for all these elements?
@tooky from the discussion we had on the mailing list I've got an impression that there is no name property in Gherkin, only title and description.
@mattwynne @aslakhellesoy am I right?
Formally, it goes like this:
So the code in Cucumber is wrong. It's really wrong actually. IIRC it has the following wrong:
We should get rid of #title altogether, and change #name to return the name from Gherkin.
However we need to be aware that this is changing the API. People like Calabash and Jetbrains particularly will care about this.
Perhaps we could just change #name in 1.3.0 and remove title in 2.0. What do you think?
Thanks for the notification. We would prefer breaking changes deferred to 2.0. We have custom reporters that depend on the semantics.
I've moved the ticket to 2.0
#name for 2.0 will return the name of the underlying Cucumber::Core::Test::Case which will always be a one-line string.