Add spec for GitHub issue 47

https://github.com/icy-arctic-fox/spectator/issues/47
This commit is contained in:
Michael Miller 2022-10-09 15:33:19 -06:00
parent e9d3f31ac3
commit 2516803b0d
No known key found for this signature in database
GPG Key ID: 32B47AE8F388A1FF
1 changed files with 18 additions and 0 deletions

View File

@ -0,0 +1,18 @@
require "../spec_helper"
Spectator.describe "GitHub Issue #47" do
class Original
def foo(arg1, arg2)
# ...
end
end
mock Original
let(fake) { mock(Original) }
specify do
expect(fake).to receive(:foo).with("arg1", arg2: "arg2")
fake.foo("arg1", "arg2")
end
end