spec/cucumber/ast/step_spec.rb in cucumber-1.2.1 vs spec/cucumber/ast/step_spec.rb in cucumber-1.2.2
- old
+ new
@@ -13,11 +13,11 @@
%w{color taste},
%w{green juicy}
])
cells = invocation_table.cells_rows[1]
step_invocation = step.step_invocation_from_cells(cells)
-
+
step_invocation.name.should == 'a green cucumber'
end
it "should use empty string for the replacement of arguments in name when replace value is nil" do
step = Step.new(1, 'Given', 'a <color>cucumber')
@@ -26,11 +26,11 @@
['color'],
[nil]
])
cells = invocation_table.cells_rows[1]
step_invocation = step.step_invocation_from_cells(cells)
-
+
step_invocation.name.should == 'a cucumber'
end
it "should replace arguments in table arg" do
arg_table = Table.new([%w{taste_<taste> color_<color>}])
@@ -41,11 +41,11 @@
%w{color taste},
%w{green juicy}
])
cells = invocation_table.cells_rows[1]
step_invocation = step.step_invocation_from_cells(cells)
-
+
step_invocation.instance_variable_get('@multiline_arg').raw.should == [%w{taste_juicy color_green}]
end
it "should replace arguments in py string arg" do
doc_string = DocString.new('taste_<taste> color_<color>', '')
@@ -56,10 +56,10 @@
%w{color taste},
%w{green juicy}
])
cells = invocation_table.cells_rows[1]
step_invocation = step.step_invocation_from_cells(cells)
-
+
step_invocation.instance_variable_get('@multiline_arg').to_step_definition_arg.should == 'taste_juicy color_green'
end
end
end
end