Re: Cucumber: Migrating RSpec Story L isteners to Cucumber

No advice on that?

Should i open a ticket on Lighthouse?
I also would try to implement that…

Thanks,
Thomas

-----Ursprüngliche Nachricht-----
Von: “Thomas M.” [email protected]
Gesendet: 09.10.08 15:25:14
An: rspec-users [email protected]
Betreff: [rspec-users] Cucumber: Migrating RSpec Story Listeners to Cucumber

rspec-users mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/rspec-users


Der WEB.DE SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen!
WEB.DE Produkte Übersicht: Apps, Browser, MailCheck & Co.

Why use a cucumber_scenario method when the After method could just
pass it to the block?

Michael

On Tue, Oct 14, 2008 at 9:38 AM, Thomas M. [email protected]
wrote:

No advice on that?

Should i open a ticket on Lighthouse?

Please do.

I also would try to implement that…

Great! Some suggestions:

I’d like to be able to do something like this:

After do

cucumber_scenario would return the Scenario instance

The cucumber_scenario method could be defined in a similar way to

#run_step,

see Executor#define_step_call_methods

if cucumber_scenario.successful?
take_screenshot(cucumber_scenario.id) # Each scenario should have
a unique id that can be used in e.g. file names.
end
end

Aslak

On Tue, Oct 14, 2008 at 1:49 PM, aslak hellesoy
[email protected] wrote:

On Tue, Oct 14, 2008 at 5:29 PM, Michael L. [email protected] wrote:

Why use a cucumber_scenario method when the After method could just pass it
to the block?

Good idea!

Can the Before do the same? Then you could grab the name or whatever
before printing anything out.

On Tue, Oct 14, 2008 at 3:39 PM, David C. [email protected]
wrote:

Based on Aslak’s example and the content in the ticket and this thread
I think that is the intent. Although, mentioned in passing it as an
example in the After, Aslak’s code exactly on the ticket showed only
passing the scenario through to the Before as a block argument.

The ticket has been updated, perhaps we should defer future
communication on this thread to the ticket?


Zach D.
http://www.continuousthinking.com

On Tue, Oct 14, 2008 at 9:52 PM, Zach D. [email protected]
wrote:

before printing anything out.

Based on Aslak’s example and the content in the ticket and this thread
I think that is the intent. Although, mentioned in passing it as an
example in the After, Aslak’s code exactly on the ticket showed only
passing the scenario through to the Before as a block argument.

The ticket has been updated, perhaps we should defer future
communication on this thread to the ticket?

Yes, let’s

On Tue, Oct 14, 2008 at 5:29 PM, Michael L. [email protected] wrote:

Why use a cucumber_scenario method when the After method could just pass it
to the block?

Good idea!