Hi all!
I want to test my parse sentence module using a lot of examples. I know
that I can create cycle in rspec as
describe ".test" do
{"a" => "a", "b" => "b", "c" => "c"}.each do |m, e|
it "#{m} to be equal #{a}" do
expect(m).to eq(e)
end
end
end
Does exist any method to load test cases ({"a" => "a", "b" => "b", "c" =>
"c"}) from file or from method? Helper metods are unavailable in
describe/context blocks.
I don't want to do it in one `it` block as one test.
Thanks!
--
You received this message because you are subscribed to the Google Groups
"rspec" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/rspec/21381216-c419-47b5-8fe9-7cfe6a07ffea%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.