Update existing specs to support conditions

This commit is contained in:
Michael Miller 2019-01-11 10:09:40 -07:00
parent 38202ff605
commit d9363fc8a7
8 changed files with 171 additions and 169 deletions

View file

@ -34,8 +34,8 @@ class SpyExample < Spectator::RunnableExample
# Creates a spy example.
# The block passed to this method will be executed when the example runs.
def self.create(hooks = Spectator::ExampleHooks.empty, &block)
group = Spectator::RootExampleGroup.new(hooks)
def self.create(hooks = Spectator::ExampleHooks.empty, conditions = Spectator::ExampleConditions.empty, &block)
group = Spectator::RootExampleGroup.new(hooks, conditions)
values = Spectator::Internals::SampleValues.empty
new(group, values).tap do |example|
group.children = [example.as(Spectator::ExampleComponent)]