Fixes for enumerating examples

This commit is contained in:
Michael Miller 2018-09-20 18:41:36 -06:00
parent 39be62c511
commit cba0abc7f1

View file

@ -9,16 +9,18 @@ module Spectator
end
def example_count
super.example_count * @collection.size
super * @collection.size
end
def all_examples
Array(Example).new(example_count).tap do |array|
examples = super
examples.each do |example|
@mapping[example] = value
@collection.each do |value|
examples.each do |example|
@mapping[example] = value
end
array.concat(examples)
end
array.concat(examples)
end
end