chore: Use availability in dashboard presence toggle (#3212)
This commit is contained in:
parent
ed25435ac2
commit
cebd34053b
7 changed files with 22 additions and 19 deletions
|
@ -115,9 +115,9 @@ describe('#actions', () => {
|
|||
});
|
||||
});
|
||||
|
||||
describe('#setCurrentUserAvailabilityStatus', () => {
|
||||
describe('#setCurrentUserAvailability', () => {
|
||||
it('sends correct mutations if user id is available', async () => {
|
||||
actions.setCurrentUserAvailabilityStatus(
|
||||
actions.setCurrentUserAvailability(
|
||||
{
|
||||
commit,
|
||||
state: { currentUser: { id: 1 } },
|
||||
|
@ -130,7 +130,7 @@ describe('#actions', () => {
|
|||
});
|
||||
|
||||
it('does not send correct mutations if user id is not available', async () => {
|
||||
actions.setCurrentUserAvailabilityStatus(
|
||||
actions.setCurrentUserAvailability(
|
||||
{
|
||||
commit,
|
||||
state: { currentUser: { id: 1 } },
|
||||
|
|
|
@ -20,11 +20,11 @@ describe('#getters', () => {
|
|||
|
||||
it('get', () => {
|
||||
expect(
|
||||
getters.getCurrentUserAvailabilityStatus({
|
||||
getters.getCurrentUserAvailability({
|
||||
currentAccountId: 1,
|
||||
currentUser: {
|
||||
id: 1,
|
||||
accounts: [{ id: 1, availability_status: 'busy' }],
|
||||
accounts: [{ id: 1, availability: 'busy' }],
|
||||
},
|
||||
})
|
||||
).toEqual('busy');
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue