feat: Add team assignment & filter APIs (#1712)

This commit is contained in:
Sojan Jose
2021-01-31 12:40:02 +05:30
committed by GitHub
parent b0563a666e
commit 0ff81e3b53
4 changed files with 70 additions and 5 deletions

View File

@@ -37,6 +37,17 @@ describe ::ConversationFinder do
end
end
context 'with team' do
let(:team) { create(:team, account: account) }
let(:params) { { team_id: team.id } }
it 'filter conversations by team' do
create(:conversation, account: account, inbox: inbox, team: team)
result = conversation_finder.perform
expect(result[:conversations].count).to be 1
end
end
context 'with labels' do
let(:params) { { labels: ['resolved'] } }