diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2023-12-19 14:01:45 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2023-12-19 14:01:45 +0300 |
commit | 9297025d0b7ddf095eb618dfaaab2ff8f2018d8b (patch) | |
tree | 865198c01d1824a9b098127baa3ab980c9cd2c06 /spec/lib/banzai/filter/references/commit_reference_filter_spec.rb | |
parent | 6372471f43ee03c05a7c1f8b0c6ac6b8a7431dbe (diff) |
Add latest changes from gitlab-org/gitlab@16-7-stable-eev16.7.0-rc42
Diffstat (limited to 'spec/lib/banzai/filter/references/commit_reference_filter_spec.rb')
-rw-r--r-- | spec/lib/banzai/filter/references/commit_reference_filter_spec.rb | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/spec/lib/banzai/filter/references/commit_reference_filter_spec.rb b/spec/lib/banzai/filter/references/commit_reference_filter_spec.rb index 6e0f9eda0e2..35a3f20f7b7 100644 --- a/spec/lib/banzai/filter/references/commit_reference_filter_spec.rb +++ b/spec/lib/banzai/filter/references/commit_reference_filter_spec.rb @@ -287,12 +287,18 @@ RSpec.describe Banzai::Filter::References::CommitReferenceFilter, feature_catego reference_filter(markdown) end.count - markdown = "#{commit_reference} 8b95f2f1 8b95f2f2 8b95f2f3 #{commit2_reference} #{commit3_reference}" + expect(max_count).to eq 0 + + markdown = "#{commit_reference} 8b95f2f1 8b95f2f2 8b95f2f3 #{commit2_reference} #{commit3_reference}" # Commits are not DB entries, they are on the project itself. - # So adding commits from two more projects to the markdown should - # only increase by 1 query - max_count += 1 + # 1 for for routes to find routes.source_id of projects matching paths + # 1 for projects belonging to the above routes + # 1 for preloading routes of the projects + # 1 for loading the namespaces associated to the project + # 1 for loading the routes associated with the namespace + # Total = 5 + max_count += 5 expect do reference_filter(markdown) |