Skip to content

Commit 3e64f86

Browse files
committed
Auto-correct rubocop offenses
1 parent 12e2bf1 commit 3e64f86

File tree

3 files changed

+11
-11
lines changed

3 files changed

+11
-11
lines changed

spec/unit/facter/pip_version_spec.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
context 'returns nil when pip not present' do
3838
it do
3939
allow(Facter::Util::Resolution).to receive(:which).with('pip').and_return(false)
40-
expect(Facter.value(:pip_version)).to eq(nil)
40+
expect(Facter.value(:pip_version)).to be_nil
4141
end
4242
end
4343
end
@@ -54,7 +54,7 @@
5454
context 'returns nil when pip2 not present' do
5555
it do
5656
allow(Facter::Util::Resolution).to receive(:which).with('pip2').and_return(false)
57-
expect(Facter.value(:pip2_version)).to eq(nil)
57+
expect(Facter.value(:pip2_version)).to be_nil
5858
end
5959
end
6060
end
@@ -71,7 +71,7 @@
7171
context 'returns nil when pip3 not present' do
7272
it do
7373
allow(Facter::Util::Resolution).to receive(:which).with('pip3').and_return(false)
74-
expect(Facter.value(:pip3_version)).to eq(nil)
74+
expect(Facter.value(:pip3_version)).to be_nil
7575
end
7676
end
7777
end

spec/unit/facter/python_release_spec.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
it do
3232
allow(Facter::Util::Resolution).to receive(:exec).and_return(false)
3333
allow(Facter::Util::Resolution).to receive(:which).with('python').and_return(false)
34-
expect(Facter.value(:python_release)).to eq(nil)
34+
expect(Facter.value(:python_release)).to be_nil
3535
end
3636
end
3737
end
@@ -60,15 +60,15 @@
6060
allow(Facter::Util::Resolution).to receive(:which).with('python').and_return(true)
6161
allow(Facter::Util::Resolution).to receive(:exec).with('python -V 2>&1').and_return(python3_version_output)
6262
allow(Facter::Util::Resolution).to receive(:which).with('python2').and_return(false)
63-
expect(Facter.value(:python2_release)).to eq(nil)
63+
expect(Facter.value(:python2_release)).to be_nil
6464
end
6565
end
6666

6767
context 'returns nil when `python2` and `python` are absent' do
6868
it do
6969
allow(Facter::Util::Resolution).to receive(:which).with('python').and_return(false)
7070
allow(Facter::Util::Resolution).to receive(:which).with('python2').and_return(false)
71-
expect(Facter.value(:python2_release)).to eq(nil)
71+
expect(Facter.value(:python2_release)).to be_nil
7272
end
7373
end
7474
end
@@ -85,7 +85,7 @@
8585
context 'returns nil when `python3` not present' do
8686
it do
8787
allow(Facter::Util::Resolution).to receive(:which).with('python3').and_return(false)
88-
expect(Facter.value(:python3_release)).to eq(nil)
88+
expect(Facter.value(:python3_release)).to be_nil
8989
end
9090
end
9191
end

spec/unit/facter/python_version_spec.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
context 'returns nil when `python` not present' do
3131
it do
3232
allow(Facter::Util::Resolution).to receive(:which).with('python').and_return(false)
33-
expect(Facter.value(:python_version)).to eq(nil)
33+
expect(Facter.value(:python_version)).to be_nil
3434
end
3535
end
3636
end
@@ -59,15 +59,15 @@
5959
allow(Facter::Util::Resolution).to receive(:which).with('python').and_return(true)
6060
allow(Facter::Util::Resolution).to receive(:exec).with('python -V 2>&1').and_return(python3_version_output)
6161
allow(Facter::Util::Resolution).to receive(:which).with('python2').and_return(false)
62-
expect(Facter.value(:python2_version)).to eq(nil)
62+
expect(Facter.value(:python2_version)).to be_nil
6363
end
6464
end
6565

6666
context 'returns nil when `python2` and `python` are absent' do
6767
it do
6868
allow(Facter::Util::Resolution).to receive(:which).with('python2').and_return(false)
6969
allow(Facter::Util::Resolution).to receive(:which).with('python').and_return(false)
70-
expect(Facter.value(:python2_version)).to eq(nil)
70+
expect(Facter.value(:python2_version)).to be_nil
7171
end
7272
end
7373
end
@@ -84,7 +84,7 @@
8484
context 'returns nil when `python3` not present' do
8585
it do
8686
allow(Facter::Util::Resolution).to receive(:which).with('python3').and_return(false)
87-
expect(Facter.value(:python3_version)).to eq(nil)
87+
expect(Facter.value(:python3_version)).to be_nil
8888
end
8989
end
9090
end

0 commit comments

Comments
 (0)