Commit 939cd374 authored by DJ Mountney's avatar DJ Mountney

In order to use chomp! on the input later, we need to dup the ARGV input string for keys

Also updated the gitlab_key tests to freeze the ARGV variables.
parent 1e3d15a7
......@@ -22,7 +22,8 @@ class GitlabKeys
def initialize
@command = ARGV.shift
@key_id = ARGV.shift
@key = ARGV.shift
key = ARGV.shift
@key = key.dup if key
@auth_file = GitlabConfig.new.auth_file
end
......
......@@ -284,7 +284,7 @@ describe GitlabKeys do
def argv(*args)
args.each_with_index do |arg, i|
ARGV[i] = arg
ARGV[i] = arg.freeze
end
end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment