Feature: As an end-user, I should be able to see the list of agents in the widget. (#461)
Co-authored-by: Pranav Raj S <pranavrajs@gmail.com>
This commit is contained in:
committed by
GitHub
parent
33e0bd434b
commit
83b0bb4062
@@ -0,0 +1,30 @@
|
||||
import { getters } from '../../agent';
|
||||
import { agents } from './data';
|
||||
|
||||
describe('#getters', () => {
|
||||
it('availableAgents', () => {
|
||||
const state = {
|
||||
records: agents,
|
||||
};
|
||||
expect(getters.availableAgents(state)).toEqual([
|
||||
{
|
||||
id: 1,
|
||||
name: 'John',
|
||||
avatar_url: '',
|
||||
availability_status: 'online',
|
||||
},
|
||||
{
|
||||
id: 3,
|
||||
name: 'Pranav',
|
||||
avatar_url: '',
|
||||
availability_status: 'online',
|
||||
},
|
||||
{
|
||||
id: 4,
|
||||
name: 'Nithin',
|
||||
avatar_url: '',
|
||||
availability_status: 'online',
|
||||
},
|
||||
]);
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user