Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2019-12-17 21:07:48 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2019-12-17 21:07:48 +0300
commite72386771751fb22245bc6604fef236a2ee130cb (patch)
tree7cf54bca933159cb177d3caa2f139f87d6d30391 /spec/javascripts/diffs/store/actions_spec.js
parentc2b98d3dbd47ab92c79c702276fe9130d9a28036 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/javascripts/diffs/store/actions_spec.js')
-rw-r--r--spec/javascripts/diffs/store/actions_spec.js10
1 files changed, 6 insertions, 4 deletions
diff --git a/spec/javascripts/diffs/store/actions_spec.js b/spec/javascripts/diffs/store/actions_spec.js
index 589bd0e649a..b23334d38dc 100644
--- a/spec/javascripts/diffs/store/actions_spec.js
+++ b/spec/javascripts/diffs/store/actions_spec.js
@@ -147,13 +147,15 @@ describe('DiffsStoreActions', () => {
describe('fetchDiffFilesBatch', () => {
it('should fetch batch diff files', done => {
const endpointBatch = '/fetch/diffs_batch';
- const batch1 = `${endpointBatch}?per_page=${DIFFS_PER_PAGE}`;
- const batch2 = `${endpointBatch}?per_page=${DIFFS_PER_PAGE}&page=2`;
const mock = new MockAdapter(axios);
const res1 = { diff_files: [], pagination: { next_page: 2 } };
const res2 = { diff_files: [], pagination: {} };
- mock.onGet(batch1).reply(200, res1);
- mock.onGet(batch2).reply(200, res2);
+ mock
+ .onGet(endpointBatch, { params: { page: undefined, per_page: DIFFS_PER_PAGE, w: '1' } })
+ .reply(200, res1);
+ mock
+ .onGet(endpointBatch, { params: { page: 2, per_page: DIFFS_PER_PAGE, w: '1' } })
+ .reply(200, res2);
testAction(
fetchDiffFilesBatch,