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:
authorRobert Speicher <rspeicher@gmail.com>2019-02-26 21:22:10 +0300
committerRobert Speicher <rspeicher@gmail.com>2019-02-26 21:22:10 +0300
commit9b3a0de5ed44fdcdb01bd520ad8e0ec8e3ab7ea6 (patch)
tree0baa0af87e391ed2c2d1b78daf7a08f15d0b06d4 /spec/controllers
parentf5201a816f2eff9393e16f362403451e5d86ee6c (diff)
parente7e5efd1319c1eb11e52e33f12f4c25c07682dc0 (diff)
Merge branch '57905-etag-caching-probably-broken-since-11-5-0' into 'master'
Fix ETag caching not being used for AJAX requests Closes #57905 See merge request gitlab-org/gitlab-ce!25400
Diffstat (limited to 'spec/controllers')
-rw-r--r--spec/controllers/application_controller_spec.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/spec/controllers/application_controller_spec.rb b/spec/controllers/application_controller_spec.rb
index c9e520317e8..dca74bd5f84 100644
--- a/spec/controllers/application_controller_spec.rb
+++ b/spec/controllers/application_controller_spec.rb
@@ -665,6 +665,14 @@ describe ApplicationController do
expect(response.headers['Cache-Control']).to eq 'max-age=0, private, must-revalidate, no-store'
end
+
+ it 'does not set the "no-store" header for XHR requests' do
+ sign_in(user)
+
+ get :index, xhr: true
+
+ expect(response.headers['Cache-Control']).to eq 'max-age=0, private, must-revalidate'
+ end
end
end
end