diff --git a/src/spectator/mocks/exception_method_stub.cr b/src/spectator/mocks/exception_method_stub.cr index 2f223fd..ce34b64 100644 --- a/src/spectator/mocks/exception_method_stub.cr +++ b/src/spectator/mocks/exception_method_stub.cr @@ -7,7 +7,7 @@ module Spectator::Mocks super(name, location, args) end - def call(_args : GenericArguments(T, NT), &_original : -> RT) forall T, NT, RT + def call(_args : GenericArguments(T, NT), & : -> RT) forall T, NT, RT raise @exception end end diff --git a/src/spectator/mocks/method_stub.cr b/src/spectator/mocks/method_stub.cr index 9ad78a3..bf9d0e6 100644 --- a/src/spectator/mocks/method_stub.cr +++ b/src/spectator/mocks/method_stub.cr @@ -14,9 +14,9 @@ module Spectator::Mocks @name == call.name end - abstract def call(args : GenericArguments(T, NT), &original : -> RT) forall T, NT, RT + abstract def call(args : GenericArguments(T, NT), & : -> RT) forall T, NT, RT - def call!(args : GenericArguments(T, NT), &original : -> RT) : RT forall T, NT, RT + def call!(args : GenericArguments(T, NT), & : -> RT) : RT forall T, NT, RT value = call(args) { |*ya| yield *ya } if value.is_a?(RT) value.as(RT) diff --git a/src/spectator/mocks/multi_value_method_stub.cr b/src/spectator/mocks/multi_value_method_stub.cr index f025271..944e985 100644 --- a/src/spectator/mocks/multi_value_method_stub.cr +++ b/src/spectator/mocks/multi_value_method_stub.cr @@ -10,7 +10,7 @@ module Spectator::Mocks raise ArgumentError.new("Values must have at least one item") if @values.size < 1 end - def call(_args : GenericArguments(T, NT), &_original : -> RT) forall T, NT, RT + def call(_args : GenericArguments(T, NT), & : -> RT) forall T, NT, RT value = @values[@index] @index += 1 if @index < @values.size - 1 value diff --git a/src/spectator/mocks/nil_method_stub.cr b/src/spectator/mocks/nil_method_stub.cr index 1e87db6..38b1aab 100644 --- a/src/spectator/mocks/nil_method_stub.cr +++ b/src/spectator/mocks/nil_method_stub.cr @@ -4,7 +4,7 @@ require "./value_method_stub" module Spectator::Mocks class NilMethodStub < GenericMethodStub(Nil) - def call(_args : GenericArguments(T, NT), &_original : -> RT) forall T, NT, RT + def call(_args : GenericArguments(T, NT), & : -> RT) forall T, NT, RT nil end diff --git a/src/spectator/mocks/original_method_stub.cr b/src/spectator/mocks/original_method_stub.cr index 2097eb6..041325a 100644 --- a/src/spectator/mocks/original_method_stub.cr +++ b/src/spectator/mocks/original_method_stub.cr @@ -3,7 +3,7 @@ require "./generic_method_stub" module Spectator::Mocks class OriginalMethodStub < GenericMethodStub(Nil) - def call(_args : GenericArguments(T, NT), &_original : -> RT) forall T, NT, RT + def call(_args : GenericArguments(T, NT), & : -> RT) forall T, NT, RT yield end end diff --git a/src/spectator/mocks/proc_method_stub.cr b/src/spectator/mocks/proc_method_stub.cr index de3a68d..a72eb3c 100644 --- a/src/spectator/mocks/proc_method_stub.cr +++ b/src/spectator/mocks/proc_method_stub.cr @@ -11,7 +11,7 @@ module Spectator::Mocks ProcMethodStub.new(name, location, block, args) end - def call(_args : GenericArguments(T, NT), &_original : -> RT) forall T, NT, RT + def call(_args : GenericArguments(T, NT), & : -> RT) forall T, NT, RT @proc.call end end diff --git a/src/spectator/mocks/value_method_stub.cr b/src/spectator/mocks/value_method_stub.cr index d3e7f5e..cda6b22 100644 --- a/src/spectator/mocks/value_method_stub.cr +++ b/src/spectator/mocks/value_method_stub.cr @@ -7,7 +7,7 @@ module Spectator::Mocks super(name, location, args) end - def call(_args : GenericArguments(T, NT), &_original : -> RT) forall T, NT, RT + def call(_args : GenericArguments(T, NT), & : -> RT) forall T, NT, RT @value end end