blob: 1a6b3f20b1bf9210cee4840630398116aebdb53b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
# frozen_string_literal: true
RSpec.describe '`spandx scan` command', type: :cli do
it 'executes `spandx help scan` command successfully' do
output = `spandx help scan`
expect(output).to eq(fixture_file_content('help-scan.expected'))
end
it 'executes `spandx scan Gemfile.lock`' do
output = `spandx scan #{fixture_file('bundler/Gemfile.lock')} 2> /dev/null`
expect(output).to eq(fixture_file_content('bundler/Gemfile.lock.expected'))
end
it 'executes `spandx scan gems.lock' do
output = `spandx scan #{fixture_file('bundler/gems.lock')} 2> /dev/null`
expect(output).to eq(fixture_file_content('bundler/gems.lock.expected'))
end
it 'executes `spandx scan Pipfile.lock`' do
output = `spandx scan #{fixture_file('pip/Pipfile.lock')} 2> /dev/null`
expect(output).to eq(fixture_file_content('pip/Pipfile.lock.expected'))
end
it 'executes `spandx scan yarnfile.lock`' do
output = `spandx scan #{fixture_file('js/yarn.lock')} 2> /dev/null`
expect(output).to eq(fixture_file_content('js/yarn.lock.expected'))
end
it 'executes `spandx scan composer.lock`' do
output = `spandx scan #{fixture_file('composer/composer.lock')} 2> /dev/null`
expect(output).to eq(fixture_file_content('composer/composer.lock.expected'))
end
end
|