Permalink
Browse files

Don't use assert for steps, use FAIL instead.

This leads to reproducible error messages across cl implementations, and should make clucumber
work on more than just Allegro CL (alisp) and SBCL.
  • Loading branch information...
1 parent e94b73d commit 3545f68713513d5b288070fcae1dab1cad545326 @antifuchs antifuchs committed Jul 12, 2010
Showing with 3 additions and 3 deletions.
  1. +1 −1 features/step_definitions/cucumber_steps.rb
  2. +2 −2 features/success-and-failure.feature
@@ -7,7 +7,7 @@
## This may be interesting for the aruba project (if we drop the :
Then /^it should (pass|fail) with exactly:$/ do |pass_fail, exact_output|
- strip_duration(combined_output.downcase).should == exact_output.downcase
+ strip_duration(combined_output).should == exact_output
if pass_fail == 'pass'
Then "the exit status should be 0"
else
@@ -46,7 +46,7 @@ Scenario: Failing simple scenario
Given a file named "features/step_definitions/fail.lisp" with:
"""
(Given* #?"^this step fails" ()
- (assert (= 1 0)))
+ (fail "Fail!"))
"""
When I run "cucumber -f progress"
@@ -56,7 +56,7 @@ Scenario: Failing simple scenario
(::) failed steps (::)
- Caught an error (The assertion (= 1 0) failed. from localhost:42427)
+ Fail! (Cucumber::WireSupport::WireException)
features/fail.feature:5:in `Given this step fails'
Failing Scenarios:

0 comments on commit 3545f68

Please sign in to comment.