We shouldn't include utility methods everywhere

This commit is contained in:
Lin Jen-Shin 2017-08-08 23:14:29 +08:00
parent e26acdb11b
commit 5d963fccab
2 changed files with 4 additions and 1 deletions

View File

@ -5,6 +5,8 @@ module Gitlab
TaskAbortedByUserError = Class.new(StandardError)
module TaskHelpers
extend self
# Ask if the user wants to continue
#
# Returns "yes" the user chose to continue

View File

@ -22,7 +22,8 @@ describe 'gitlab:shell rake tasks' do
describe 'create_hooks task' do
it 'calls gitlab-shell bin/create_hooks' do
expect_any_instance_of(Object).to receive(:system)
.with("#{Gitlab.config.gitlab_shell.path}/bin/create-hooks", *repository_storage_paths_args)
.with("#{Gitlab.config.gitlab_shell.path}/bin/create-hooks",
*Gitlab::TaskHelpers.repository_storage_paths_args)
run_rake_task('gitlab:shell:create_hooks')
end