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:
authorJacob Vosmaer <contact@jacobvosmaer.nl>2016-03-03 20:38:44 +0300
committerJacob Vosmaer <contact@jacobvosmaer.nl>2016-03-03 20:38:44 +0300
commit1764e1b7cb2bffb9b4c4a69991fe2c4d21ce5459 (patch)
treeb48ca1bad0532a37a19f00f0903a778109a16a3d /features/steps/project/commits/commits.rb
parente1bc808746523309476913033b104345c06c4816 (diff)
Use Gitlab::Git::DiffCollections
Diffstat (limited to 'features/steps/project/commits/commits.rb')
-rw-r--r--features/steps/project/commits/commits.rb7
1 files changed, 5 insertions, 2 deletions
diff --git a/features/steps/project/commits/commits.rb b/features/steps/project/commits/commits.rb
index f9fd7332464..93c37bf507f 100644
--- a/features/steps/project/commits/commits.rb
+++ b/features/steps/project/commits/commits.rb
@@ -126,8 +126,11 @@ class Spinach::Features::ProjectCommits < Spinach::FeatureSteps
end
step 'I visit big commit page' do
- stub_const('Commit::DIFF_SAFE_FILES', 20)
- visit namespace_project_commit_path(@project.namespace, @project, sample_big_commit.id)
+ # Create a temporary scope to ensure that the stub_const is removed after user
+ RSpec::Mocks.with_temporary_scope do
+ stub_const('Gitlab::Git::DiffCollection::DEFAULT_LIMITS', { max_lines: 1, max_files: 1 })
+ visit namespace_project_commit_path(@project.namespace, @project, sample_big_commit.id)
+ end
end
step 'I see big commit warning' do