Last active
November 13, 2017 13:38
-
-
Save domagude/9b5f0986b2ffcaa3f5c2c578be0d5fbf to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
... | |
context 'Scopes' do | |
it 'gets a conversation between users' do | |
user1 = create(:user) | |
user2 = create(:user) | |
create(:private_conversation, recipient_id: user1.id, sender_id: user2.id) | |
conversation = Private::Conversation.between_users(user1.id, user2.id) | |
expect(conversation.count).to eq 1 | |
end | |
end | |
... |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment