Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fix style.

  • Loading branch information...
commit fd4aa53382574f062cea9fc182564bce63d2b212 1 parent 0e0339e
@gabebw gabebw authored
View
14 lib/shoulda/matchers/action_controller/set_the_flash_matcher.rb
@@ -103,12 +103,20 @@ def flash_description
end
def expected_flash_invocation
- "flash#{".now" if @now}#{"[:%s]" % @key if @key}"
- end
+ now = ""
+ key = ""
- end
+ if @now
+ now = ".now"
+ end
+ if @key
+ key = "[:#{@key}]"
+ end
+ "flash#{now}#{key}"
+ end
+ end
end
end
end
View
1  spec/shoulda/action_controller/set_the_flash_matcher_spec.rb
@@ -93,7 +93,6 @@
it "should reject setting a different pattern" do
@controller.should_not set_the_flash[:notice].to(/other/)
end
-
end
context "a controller that sets multiple flash messages" do
Please sign in to comment.
Something went wrong with that request. Please try again.