diff --git a/features/step_definitions/web_steps.rb b/features/step_definitions/web_steps.rb index 4f414a41c..a9ed77abf 100644 --- a/features/step_definitions/web_steps.rb +++ b/features/step_definitions/web_steps.rb @@ -164,7 +164,7 @@ end Then /^the "([^"]*)" checkbox(?: within "([^"]*)")? should not be checked$/ do |label, selector| with_scope(selector) do field_checked = find_field(label)['checked'] - field_checked.should be false + field_checked.should be_falsey end end diff --git a/spec/models/status_message_spec.rb b/spec/models/status_message_spec.rb index 28c0411be..fc0ac505b 100644 --- a/spec/models/status_message_spec.rb +++ b/spec/models/status_message_spec.rb @@ -52,8 +52,9 @@ describe StatusMessage, :type => :model do describe '.user_tag_stream' do it 'returns tag stream thats owned or visible by' do - expect(StatusMessage).to receive(:owned_or_visible_by_user).with(bob).and_return(StatusMessage) - expect(StatusMessage).to receive(:tag_stream).with([@tag_id]) + relation = double + expect(StatusMessage).to receive(:owned_or_visible_by_user).with(bob).and_return(relation) + expect(relation).to receive(:tag_stream).with([@tag_id]) StatusMessage.user_tag_stream(bob, [@tag_id]) end