Commit caaa02b0c1c58bbfec55f6ca77fc73807b0aa31b

Authored by Diego Camarinha
Committed by Paulo Meireles
1 parent e8569682

[Mezuro] Created step for configuration without clone.

Showing 1 changed file with 15 additions and 2 deletions   Show diff stats
features/step_definitions/mezuro_steps.rb
1   -When /^I create a Mezuro (project|configuration|reading group) with the following data$/ do |type, fields|
  1 +When /^I create a Mezuro (project|reading group) with the following data$/ do |type, fields|
2 2 click_link ("Mezuro " + type)
3 3  
4 4 fields.rows_hash.each do |name, value|
5 5 When %{I fill in "#{name}" with "#{value}"}
6 6 end
7 7  
8   - click_button "Save" # Does not work without selenium?
  8 + click_button "Save"
  9 + Article.find_by_name(fields.rows_hash[:Title])
  10 +end
  11 +
  12 +When /^I create a Mezuro configuration with the following data$/ do |fields|
  13 + click_link ("Mezuro configuration")
  14 +
  15 + fields.rows_hash.each do |name, value|
  16 + if name != "Clone"
  17 + When %{I fill in "#{name}" with "#{value}"}
  18 + end
  19 + end
  20 +
  21 + click_button "Save"
9 22 Article.find_by_name(fields.rows_hash[:Title])
10 23 end
11 24  
... ...