diff options
author | Igor <idrozdov@gitlab.com> | 2019-08-09 21:01:55 +0000 |
---|---|---|
committer | Douwe Maan <douwe@gitlab.com> | 2019-08-09 21:01:55 +0000 |
commit | b99011af62935de0b15e8a314ffb7df1f8a3f303 (patch) | |
tree | f19bc1052fa1cd903a31d6f01489b56ec2bb7ead /spec/models/merge_request_spec.rb | |
parent | 43b9be9d6cf59a02ea86795a1734848615d38a26 (diff) | |
download | gitlab-ce-b99011af62935de0b15e8a314ffb7df1f8a3f303.tar.gz |
Split MR widget into cached and non-cached serializers
Splits auto-refreshing of MR widget into 2 requests:
- the one which uses etag-caching and invalidates the fields on change
- the one without caching
The idea is to gradually move all the fields to etag-cached endpoint
Diffstat (limited to 'spec/models/merge_request_spec.rb')
-rw-r--r-- | spec/models/merge_request_spec.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/spec/models/merge_request_spec.rb b/spec/models/merge_request_spec.rb index 6a5bd276233..53424204db7 100644 --- a/spec/models/merge_request_spec.rb +++ b/spec/models/merge_request_spec.rb @@ -1988,6 +1988,7 @@ describe MergeRequest do params = {} merge_jid = 'hash-123' + expect(merge_request).to receive(:expire_etag_cache) expect(MergeWorker).to receive(:perform_async).with(merge_request.id, user_id, params) do merge_jid end @@ -2011,6 +2012,7 @@ describe MergeRequest do .with(merge_request.id, user_id) .and_return(rebase_jid) + expect(merge_request).to receive(:expire_etag_cache) expect(merge_request).to receive(:lock!).and_call_original execute |