Skip to content

Commit

Permalink
Added test with mixed spaces and commas
Browse files Browse the repository at this point in the history
  • Loading branch information
tmuntaner committed Nov 16, 2018
1 parent f0ee920 commit 5368f80
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions spec/lib/rmt/cli/products_spec.rb
Expand Up @@ -217,6 +217,17 @@
end
end

context 'with mixed spaces and commas' do
let(:argv) { ['enable', "#{product_1.id}, #{product_2.id} #{product_3.id}"] }

it 'enables product repositories' do
expect { described_class.start(argv) }.to output(expected_output).to_stdout.and output('').to_stderr
products_to_enable.flat_map(&:repositories).each do |repository|
expect(repository.mirroring_enabled).to eq(repository.enabled)
end
end
end

context 'with spaces' do
let(:argv) { ['enable', "#{product_1.id} #{product_2.id} #{product_3.id}"] }

Expand Down

0 comments on commit 5368f80

Please sign in to comment.