diff options
Diffstat (limited to 'spec/frontend/clusters_list/components/clusters_spec.js')
-rw-r--r-- | spec/frontend/clusters_list/components/clusters_spec.js | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/spec/frontend/clusters_list/components/clusters_spec.js b/spec/frontend/clusters_list/components/clusters_spec.js index e8e705a6384..20dbff9df15 100644 --- a/spec/frontend/clusters_list/components/clusters_spec.js +++ b/spec/frontend/clusters_list/components/clusters_spec.js @@ -7,6 +7,7 @@ import Clusters from '~/clusters_list/components/clusters.vue'; import ClustersEmptyState from '~/clusters_list/components/clusters_empty_state.vue'; import ClusterStore from '~/clusters_list/store'; import axios from '~/lib/utils/axios_utils'; +import { HTTP_STATUS_OK } from '~/lib/utils/http_status'; import { apiData } from '../mock_data'; describe('Clusters', () => { @@ -68,7 +69,7 @@ describe('Clusters', () => { captureException = jest.spyOn(Sentry, 'captureException'); mock = new MockAdapter(axios); - mockPollingApi(200, apiData, paginationHeader()); + mockPollingApi(HTTP_STATUS_OK, apiData, paginationHeader()); return createWrapper({}); }); @@ -255,7 +256,7 @@ describe('Clusters', () => { const totalSecondPage = 500; beforeEach(() => { - mockPollingApi(200, apiData, paginationHeader(totalFirstPage, perPage, 1)); + mockPollingApi(HTTP_STATUS_OK, apiData, paginationHeader(totalFirstPage, perPage, 1)); return createWrapper({}); }); @@ -269,7 +270,7 @@ describe('Clusters', () => { describe('when updating currentPage', () => { beforeEach(() => { - mockPollingApi(200, apiData, paginationHeader(totalSecondPage, perPage, 2)); + mockPollingApi(HTTP_STATUS_OK, apiData, paginationHeader(totalSecondPage, perPage, 2)); // setData usage is discouraged. See https://gitlab.com/groups/gitlab-org/-/epics/7330 for details // eslint-disable-next-line no-restricted-syntax wrapper.setData({ currentPage: 2 }); |