Pass example proc to around_each hook if there are no arguments

This commit is contained in:
Michael Miller 2020-03-03 15:20:25 -07:00
parent 5543c07766
commit d0f229c659

View file

@ -39,7 +39,7 @@ module Spectator
end
macro around_each(&block)
def %hook({{block.args.splat}}) : Nil
def %hook({{block.args.first || :example.id}}) : Nil
{{block.body}}
end