summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorKyrylo Silin <silin@kyrylo.org>2019-03-24 14:30:00 +0200
committerKyrylo Silin <silin@kyrylo.org>2019-03-24 14:30:00 +0200
commitb85073f80833b4377ea92bfcfb93cb03a2773559 (patch)
treed6b27a3eab4e76b8cd4fb0c82327f9fc1e9b85ee /spec
parentb938bddf0a0825ee3f61768bd95dc2d80c2714b7 (diff)
downloadpry-b85073f80833b4377ea92bfcfb93cb03a2773559.tar.gz
rubocop: fix offences of the Style/CaseEquality cop
Diffstat (limited to 'spec')
-rw-r--r--spec/config_spec.rb10
-rw-r--r--spec/support/repl_tester.rb4
2 files changed, 3 insertions, 11 deletions
diff --git a/spec/config_spec.rb b/spec/config_spec.rb
index 08c6cbf6..a4e09613 100644
--- a/spec/config_spec.rb
+++ b/spec/config_spec.rb
@@ -19,10 +19,9 @@ RSpec.describe Pry::Config do
end
it "recursively walks an Array" do
- c = described_class.from_hash(ary: [{ number: 2 }, Object, BasicObject.new])
+ c = described_class.from_hash(ary: [{ number: 2 }, Object])
expect(c.ary[0].number).to eq(2)
expect(c.ary[1]).to eq(Object)
- expect(BasicObject === c.ary[2]).to be(true)
end
end
@@ -276,13 +275,6 @@ RSpec.describe Pry::Config do
expect(c['foo']).to_not equal(c['foo'])
end
end
-
- context "when returning an instance of BasicObject" do
- it "returns without raising an error" do
- c = described_class.from_hash(foo: BasicObject.new)
- expect(BasicObject === c['foo']).to be(true)
- end
- end
end
describe "#eager_load!" do
diff --git a/spec/support/repl_tester.rb b/spec/support/repl_tester.rb
index 2298194b..ea0419e7 100644
--- a/spec/support/repl_tester.rb
+++ b/spec/support/repl_tester.rb
@@ -70,13 +70,13 @@ class ReplTester
# Assert that the current prompt matches the given string or regex.
def prompt(match)
- match.should === last_prompt
+ match.should === last_prompt # rubocop:disable Style/CaseEquality
end
# Assert that the most recent output (since the last time input was called)
# matches the given string or regex.
def output(match)
- match.should === @pry.output.string.chomp
+ match.should === @pry.output.string.chomp # rubocop:disable Style/CaseEquality
end
# Assert that the Pry session ended naturally after the last input.