Skip to content

@abyx /beautiful_and_dry.rb
Created

Embed URL

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
commentor.should_receive(:add).with(anonymous_comment)
# This
response['X-Runtime'].should =~ /[\d\.]+/
# .. or this?
response['X-Runtime'].should be_a_number
RSpec::Matchers.define :be_a_multiple_of do |expected|
match do |actual|
actual % expected == 0
end
end
expected_comment = Comment.new(anonymous: true, user: "the dude", reply_to: nil)
commentor.should_receive(:add).with(expected_comment)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.