diff options
Diffstat (limited to 'spec/frontend/operation_settings/store/mutations_spec.js')
-rw-r--r-- | spec/frontend/operation_settings/store/mutations_spec.js | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/spec/frontend/operation_settings/store/mutations_spec.js b/spec/frontend/operation_settings/store/mutations_spec.js index 1854142c89a..88eb66095ad 100644 --- a/spec/frontend/operation_settings/store/mutations_spec.js +++ b/spec/frontend/operation_settings/store/mutations_spec.js @@ -1,5 +1,6 @@ import mutations from '~/operation_settings/store/mutations'; import createState from '~/operation_settings/store/state'; +import { timezones } from '~/monitoring/format_date'; describe('operation settings mutations', () => { let localState; @@ -13,7 +14,16 @@ describe('operation settings mutations', () => { const mockUrl = 'mockUrl'; mutations.SET_EXTERNAL_DASHBOARD_URL(localState, mockUrl); - expect(localState.externalDashboardUrl).toBe(mockUrl); + expect(localState.externalDashboard.url).toBe(mockUrl); + }); + }); + + describe('SET_DASHBOARD_TIMEZONE', () => { + it('sets dashboardTimezoneSetting', () => { + mutations.SET_DASHBOARD_TIMEZONE(localState, timezones.LOCAL); + + expect(localState.dashboardTimezone.selected).not.toBeUndefined(); + expect(localState.dashboardTimezone.selected).toBe(timezones.LOCAL); }); }); }); |