Skip to content

Commit 8840b86

Browse files
committed
(CONT-801) Fix cop error
1 parent e1a809d commit 8840b86

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

spec/functions/loadjson_spec.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,9 @@
2828
before(:each) do
2929
allow(File).to receive(:exists?).with(filename).and_return(false).once
3030
if Puppet::PUPPETVERSION[0].to_i < 8
31-
allow(PSON).not_to receive(:load)
31+
allow(PSON).to receive(:load).never # rubocop:disable RSpec/ReceiveNever Switching to not_to receive breaks testing in this case
3232
else
33-
allow(JSON).not_to receive(:parse)
33+
allow(JSON).to receive(:parse).never # rubocop:disable RSpec/ReceiveNever
3434
end
3535
end
3636

spec/unit/facter/util/puppet_settings_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
describe '#with_puppet' do
88
context 'without Puppet loaded' do
99
before(:each) do
10-
allow(Module).to receive(:const_get).with('Puppet').and_raise(NameError)
10+
allow(Module).to receive(:const_get).with(:Puppet).and_raise(NameError)
1111
end
1212

1313
it 'is nil' do

0 commit comments

Comments
 (0)