feat: Add draft messages store (#7476)
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
import { getters } from '../../draftMessages';
|
||||
import { data } from './fixtures';
|
||||
|
||||
describe('#getters', () => {
|
||||
it('return the payload if key is present', () => {
|
||||
const state = {
|
||||
records: data,
|
||||
};
|
||||
expect(getters.get(state)('draft-32-REPLY')).toEqual('Hey how ');
|
||||
});
|
||||
|
||||
it('return empty string if key is not present', () => {
|
||||
const state = {
|
||||
records: data,
|
||||
};
|
||||
expect(getters.get(state)('draft-22-REPLY')).toEqual('');
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user