debian-mirror-gitlab/spec/frontend/sidebar/components/incidents/escalation_utils_spec.js

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

19 lines
556 B
JavaScript
Raw Normal View History

2022-05-07 20:08:51 +05:30
import { STATUS_ACKNOWLEDGED } from '~/sidebar/components/incidents/constants';
import { getStatusLabel } from '~/sidebar/components/incidents/utils';
describe('EscalationUtils', () => {
describe('getStatusLabel', () => {
it('returns a label when provided with a valid status', () => {
const label = getStatusLabel(STATUS_ACKNOWLEDGED);
expect(label).toEqual('Acknowledged');
});
it("returns 'None' when status is null", () => {
const label = getStatusLabel(null);
expect(label).toEqual('None');
});
});
});