diff options
author | Robert Speicher <robert@gitlab.com> | 2017-08-09 16:35:33 +0000 |
---|---|---|
committer | Robert Speicher <robert@gitlab.com> | 2017-08-09 16:35:33 +0000 |
commit | 420d835e5fb41e1c3291a814f807b555b24646ca (patch) | |
tree | a9f3ee72967dbf58fec780b8e860bb88c8531f39 /spec/support | |
parent | 08b365a1b72cb8c37ece2214846ed0945d7cbeac (diff) | |
parent | 77f10d55deb6a7deb35c38a30598dac256ab7266 (diff) | |
download | gitlab-ce-420d835e5fb41e1c3291a814f807b555b24646ca.tar.gz |
Merge branch '36003-do-not-include-to-kernel' into 'master'
Don't include anything to Kernel only because of tasks
Closes #36003
See merge request !13380
Diffstat (limited to 'spec/support')
-rw-r--r-- | spec/support/rake_helpers.rb | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/spec/support/rake_helpers.rb b/spec/support/rake_helpers.rb index 5cb415111d2..86bfeed107c 100644 --- a/spec/support/rake_helpers.rb +++ b/spec/support/rake_helpers.rb @@ -5,11 +5,15 @@ module RakeHelpers end def stub_warn_user_is_not_gitlab - allow_any_instance_of(Object).to receive(:warn_user_is_not_gitlab) + allow(main_object).to receive(:warn_user_is_not_gitlab) end def silence_output - allow($stdout).to receive(:puts) - allow($stdout).to receive(:print) + allow(main_object).to receive(:puts) + allow(main_object).to receive(:print) + end + + def main_object + @main_object ||= TOPLEVEL_BINDING.eval('self') end end |