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:
authorRubén Dávila <ruben@gitlab.com>2018-06-13 19:57:18 +0300
committerRubén Dávila <ruben@gitlab.com>2018-06-13 19:57:18 +0300
commit6a0178d8324964489654eb26fbefcb90bbcd1147 (patch)
treef2a74ccb9ff34995398329a523a86fad9099ab44 /spec/helpers
parentf646a8b9bc95fd6cecaa754f7dd0e8370c201502 (diff)
Invalidate cache with project details when repository is updated
The partial using this cache key was showing stale information due to the cache not being invalidated.
Diffstat (limited to 'spec/helpers')
-rw-r--r--spec/helpers/projects_helper_spec.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/spec/helpers/projects_helper_spec.rb b/spec/helpers/projects_helper_spec.rb
index d372e58f63d..815b4035114 100644
--- a/spec/helpers/projects_helper_spec.rb
+++ b/spec/helpers/projects_helper_spec.rb
@@ -90,6 +90,10 @@ describe ProjectsHelper do
expect(helper.project_list_cache_key(project)).to include(project.cache_key)
end
+ it "includes the last activity date" do
+ expect(helper.project_list_cache_key(project)).to include(project.last_activity_date)
+ end
+
it "includes the controller name" do
expect(helper.controller).to receive(:controller_name).and_return("testcontroller")