|
37 | 37 | expect { Rake::Task['license:check'].invoke }.to output(/✓.*chef-zero - 4.8.0.*Apache-2.0/).to_stdout
|
38 | 38 | end
|
39 | 39 |
|
40 |
| - it 'detects blacklisted softwares with good licenses correctly' do |
| 40 | + it 'detects denylisted softwares with good licenses correctly' do |
41 | 41 | license_info = '[
|
42 | 42 | {
|
43 | 43 | "name": "readline",
|
|
54 | 54 | ]'
|
55 | 55 | allow(File).to receive(:read).and_return(license_info)
|
56 | 56 |
|
57 |
| - expect { Rake::Task['license:check'].invoke }.to output(/readline.*Blacklisted software/).to_stdout.and raise_error(RuntimeError, "Build Aborted due to license violations") |
| 57 | + expect { Rake::Task['license:check'].invoke }.to output(/readline.*Denylisted software/).to_stdout.and raise_error(RuntimeError, "Build Aborted due to license violations") |
58 | 58 | end
|
59 | 59 |
|
60 | 60 | it 'detects bad licenses correctly' do
|
|
77 | 77 | expect { Rake::Task['license:check'].invoke }.to output(/foo.*Unacceptable license/).to_stdout.and raise_error(RuntimeError, "Build Aborted due to license violations")
|
78 | 78 | end
|
79 | 79 |
|
80 |
| - it 'detects whitelisted softwares with bad licenses correctly' do |
| 80 | + it 'detects allowlisted softwares with bad licenses correctly' do |
81 | 81 | license_info = '[
|
82 | 82 | {
|
83 | 83 | "name": "git",
|
|
94 | 94 | ]'
|
95 | 95 | allow(File).to receive(:read).and_return(license_info)
|
96 | 96 |
|
97 |
| - expect { Rake::Task['license:check'].invoke }.to output(/git.*Whitelisted software/).to_stdout |
| 97 | + expect { Rake::Task['license:check'].invoke }.to output(/git.*Allowlisted software/).to_stdout |
98 | 98 | end
|
99 | 99 |
|
100 |
| - it 'detects blacklisted softwares with unknown licenses correctly' do |
| 100 | + it 'detects denylisted softwares with unknown licenses correctly' do |
101 | 101 | license_info = '[
|
102 | 102 | {
|
103 | 103 | "name": "readline",
|
|
114 | 114 | ]'
|
115 | 115 | allow(File).to receive(:read).and_return(license_info)
|
116 | 116 |
|
117 |
| - expect { Rake::Task['license:check'].invoke }.to output(/readline.*Blacklisted software/).to_stdout.and raise_error(RuntimeError, "Build Aborted due to license violations") |
| 117 | + expect { Rake::Task['license:check'].invoke }.to output(/readline.*Denylisted software/).to_stdout.and raise_error(RuntimeError, "Build Aborted due to license violations") |
118 | 118 | end
|
119 | 119 |
|
120 |
| - it 'detects whitelisted software with unknown licenses correctly' do |
| 120 | + it 'detects allowlisted software with unknown licenses correctly' do |
121 | 121 | license_info = '[
|
122 | 122 | {
|
123 | 123 | "name": "git",
|
|
133 | 133 | }
|
134 | 134 | ]'
|
135 | 135 | allow(File).to receive(:read).and_return(license_info)
|
136 |
| - expect { Rake::Task['license:check'].invoke }.to output(/git.*Whitelisted software/).to_stdout |
| 136 | + expect { Rake::Task['license:check'].invoke }.to output(/git.*Allowlisted software/).to_stdout |
137 | 137 | end
|
138 | 138 |
|
139 | 139 | it 'should detect if install directory not found' do
|
|
0 commit comments