Skip to content
This repository has been archived by the owner on May 28, 2019. It is now read-only.

Commit

Permalink
Add "around hooks" stepdefs
Browse files Browse the repository at this point in the history
  • Loading branch information
jbpros committed Feb 22, 2012
1 parent 7b5b642 commit 80eaf4d
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions step_definitions/cucumber_stepdefs.rb
Expand Up @@ -62,6 +62,10 @@
write_passing_hook hook_type
end

Given /^a passing around hook$/ do
write_passing_hook "around"
end

Given /^a scenario without any tags$/ do
write_scenario
end
Expand Down Expand Up @@ -231,6 +235,14 @@
end
end

Then /^the around hook fires around the scenario$/ do
assert_cycle_sequence('around-pre', 'step 1', 'around-post')
end

Then /^the around hook is fired around the other hooks$/ do
assert_cycle_sequence('around-pre', 'before', 'step 1', 'after', 'around-post')
end

Then /^the received data table array equals the following:$/ do |json|
assert_data_table_equals_json(json)
end
Expand Down

0 comments on commit 80eaf4d

Please sign in to comment.