Skip to content

Commit 0ef19f0

Browse files
committed
Fix more tests
1 parent 3f7384b commit 0ef19f0

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

spec/support/unit/matchers/be_deprecated_in_favor_of.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ def matches?(old_constant_name)
1414
@old_constant_name = old_constant_name
1515
@actual_output =
1616
SuperDiff::UnitTests.capture_warnings do
17-
old_constant_name.constantize
17+
Object.const_get(old_constant_name)
1818
end
1919
@actual_output.start_with?(expected_prefix)
2020
end

spec/unit/deprecations_spec.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,8 +91,8 @@
9191
RSpec.describe old_constant_name, type: :unit do
9292
it "maps to #{new_constant_name}" do
9393
capture_warnings do
94-
expect(old_constant_name.constantize).to be(
95-
new_constant_name.constantize
94+
expect(Object.const_get(old_constant_name)).to be(
95+
Object.const_get(new_constant_name)
9696
)
9797
end
9898
end

0 commit comments

Comments
 (0)