Skip to content
This repository was archived by the owner on Nov 30, 2024. It is now read-only.

Commit 61f42f9

Browse files
authored
Merge pull request #1340 from saveriomiroddi/sav/improve_legacy_any_instance_documentation
Improve (legacy) `any_instance` documentation example
2 parents 018d0d5 + 76561bd commit 61f42f9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

features/working_with_legacy_code/any_instance.feature

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,8 +83,8 @@ Feature: Any Instance
8383
"""ruby
8484
RSpec.describe "allow_any_instance_of" do
8585
it 'yields the receiver to the block implementation' do
86-
allow_any_instance_of(String).to receive(:slice) do |value, start, length|
87-
value[start, length]
86+
allow_any_instance_of(String).to receive(:slice) do |instance, start, length|
87+
instance[start, length]
8888
end
8989
9090
expect('string'.slice(2, 3)).to eq('rin')

0 commit comments

Comments
 (0)