Implement #let!

This commit is contained in:
Michael Miller 2018-08-28 16:37:28 -06:00
parent 709b226f8e
commit b1d70453cf
1 changed files with 8 additions and 6 deletions

View File

@ -45,6 +45,8 @@ module Spectator
end
macro let(name, &block)
let!({{name}}!) {{block}}
module Context
@_%proxy : ValueProxy?
@ -57,15 +59,15 @@ module Spectator
end
end
end
def {{name.id}}!
{{block.body}}
end
end
end
def let!
raise NotImplementedError.new("Spectator::DSL#let!")
macro let!(name, &block)
module Context
def {{name.id}}
{{block.body}}
end
end
end
macro is_expected