cucumber-rails2 0.3.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (64) hide show
  1. data/.gitignore +4 -0
  2. data/HACKING.rdoc +24 -0
  3. data/History.txt +145 -0
  4. data/LICENSE +22 -0
  5. data/README.rdoc +70 -0
  6. data/Rakefile +24 -0
  7. data/VERSION +1 -0
  8. data/config/.gitignore +1 -0
  9. data/cucumber-rails2.gemspec +111 -0
  10. data/dev_tasks/cucumber.rake +5 -0
  11. data/dev_tasks/rspec.rake +13 -0
  12. data/features/rails2.feature +64 -0
  13. data/features/rails3.feature +97 -0
  14. data/features/rerun_profile.feature +39 -0
  15. data/features/step_definitions/cucumber_rails_steps.rb +35 -0
  16. data/features/support/env.rb +4 -0
  17. data/features/support/matchers/files.rb +17 -0
  18. data/generators/cucumber/USAGE +13 -0
  19. data/generators/cucumber/cucumber_generator.rb +88 -0
  20. data/generators/feature/USAGE +12 -0
  21. data/generators/feature/feature_generator.rb +47 -0
  22. data/lib/cucumber/rails/action_controller.rb +65 -0
  23. data/lib/cucumber/rails/active_record.rb +34 -0
  24. data/lib/cucumber/rails/capybara_javascript_emulation.rb +81 -0
  25. data/lib/cucumber/rails/rspec.rb +22 -0
  26. data/lib/cucumber/rails/test_unit.rb +7 -0
  27. data/lib/cucumber/rails/world.rb +48 -0
  28. data/lib/cucumber/web/tableish.rb +118 -0
  29. data/lib/generators/cucumber/feature/USAGE +16 -0
  30. data/lib/generators/cucumber/feature/feature_base.rb +29 -0
  31. data/lib/generators/cucumber/feature/feature_generator.rb +37 -0
  32. data/lib/generators/cucumber/feature/named_arg.rb +17 -0
  33. data/lib/generators/cucumber/install/USAGE +15 -0
  34. data/lib/generators/cucumber/install/install_base.rb +202 -0
  35. data/lib/generators/cucumber/install/install_generator.rb +64 -0
  36. data/spec/cucumber/web/tableish_spec.rb +192 -0
  37. data/spec/generators/cucumber/install/install_base_spec.rb +84 -0
  38. data/spec/spec.opts +2 -0
  39. data/spec/spec_helper.rb +6 -0
  40. data/templates/feature/feature.erb +63 -0
  41. data/templates/feature/steps.erb +14 -0
  42. data/templates/install/config/cucumber.yml.erb +8 -0
  43. data/templates/install/environments/cucumber.rb.erb +37 -0
  44. data/templates/install/script/cucumber +10 -0
  45. data/templates/install/step_definitions/capybara_steps.rb.erb +214 -0
  46. data/templates/install/step_definitions/web_steps_cs.rb.erb +136 -0
  47. data/templates/install/step_definitions/web_steps_da.rb.erb +114 -0
  48. data/templates/install/step_definitions/web_steps_de.rb.erb +136 -0
  49. data/templates/install/step_definitions/web_steps_es.rb.erb +136 -0
  50. data/templates/install/step_definitions/web_steps_ja.rb.erb +139 -0
  51. data/templates/install/step_definitions/web_steps_ko.rb.erb +141 -0
  52. data/templates/install/step_definitions/web_steps_no.rb.erb +114 -0
  53. data/templates/install/step_definitions/web_steps_pt-BR.rb.erb +140 -0
  54. data/templates/install/step_definitions/webrat_steps.rb.erb +276 -0
  55. data/templates/install/support/_rails_each_run.rb.erb +35 -0
  56. data/templates/install/support/_rails_prefork.rb.erb +12 -0
  57. data/templates/install/support/capybara.rb +9 -0
  58. data/templates/install/support/edit_warning.txt +5 -0
  59. data/templates/install/support/paths.rb +33 -0
  60. data/templates/install/support/rails.rb.erb +4 -0
  61. data/templates/install/support/rails_spork.rb.erb +13 -0
  62. data/templates/install/support/webrat.rb +8 -0
  63. data/templates/install/tasks/cucumber.rake.erb +48 -0
  64. metadata +143 -0
@@ -0,0 +1,136 @@
1
+ # encoding: utf-8
2
+ <%= embed_file('support/edit_warning.txt') %>
3
+
4
+ require File.expand_path(File.join(File.dirname(__FILE__), "..", "support", "paths"))
5
+
6
+ Angenommen /^(?:|ich )bin auf (.+)$/ do |page_name|
7
+ Given %{I am on #{page_name}}
8
+ end
9
+
10
+ Wenn /^(?:|ich )auf (.+) gehe$/ do |page_name|
11
+ When %{I go to #{page_name}}
12
+ end
13
+
14
+ Wenn /^(?:|ich )auf "([^"]*)" drücke$/ do |button|
15
+ When %{I press "#{button}"}
16
+ end
17
+
18
+ Wenn /^(?:|ich )auf "([^"]*)" klicke$/ do |link|
19
+ When %{I follow "#{link}"}
20
+ end
21
+
22
+ Wenn /^(?:|ich )auf "([^"]*)" innerhalb "([^"]*)" klicke$/ do |link, parent|
23
+ When %{I follow "#{link}" within "#{parent}"}
24
+ end
25
+
26
+ Wenn /^(?:|ich )"([^"]*)" mit "([^"]*)" ausfülle$/ do |field, value|
27
+ When %{I fill in "#{field}" with "#{value}"}
28
+ end
29
+
30
+ Wenn /^(?:|ich )"([^"]*)" in "([^"]*)" eingebe$/ do |value, field|
31
+ When %{I fill in "#{value}" for "#{field}"}
32
+ end
33
+
34
+ Wenn /^(?:|ich )folgendes eingebe:$/ do |fields|
35
+ When %{I fill in the following:}, fields
36
+ end
37
+
38
+ Wenn /^(?:|ich )"([^"]*)" in "([^"]*)" auswähle$/ do |value, field|
39
+ When %{I select "#{value}" from "#{field}"}
40
+ end
41
+
42
+ Wenn /^(?:|ich )"([^"]*)" als Datum und Uhrzeit auswähle$/ do |time|
43
+ When %{I select "#{time}" as the date and time}
44
+ end
45
+
46
+ Wenn /^(?:|ich )"([^"]*)" als "([^"]*)" Datum und Uhrzeit auswähle$/ do |datetime, datetime_label|
47
+ When %{I select "#{datetime}" as the "#{datetime_label}" date and time}
48
+ end
49
+
50
+ Wenn /^(?:|ich )"([^"]*)" als Uhrzeit auswähle$/ do |time|
51
+ When %{I select "#{time}" as the time}
52
+ end
53
+
54
+ Wenn /^(?:|ich )"([^"]*)" als "([^"]*)" Uhrzeit auswähle$/ do |time, time_label|
55
+ When %{I select "#{time}" as the "#{time_label}" time}
56
+ end
57
+
58
+ Wenn /^(?:|ich )"([^"]*)" als Datum auswähle$/ do |date|
59
+ When %{I select "#{date}" as the date}
60
+ end
61
+
62
+ Wenn /^(?:|ich )"([^"]*)" als "([^"]*)" Datum auswähle$/ do |date, date_label|
63
+ When %{I select "#{date}" as the "#{date_label}" date}
64
+ end
65
+
66
+ Wenn /^(?:|ich )"([^"]*)" anhake$/ do |field|
67
+ When %{I check "#{field}"}
68
+ end
69
+
70
+ Wenn /^(?:|ich )"([^"]*)" abhake$/ do |field|
71
+ When %{I uncheck "#{field}"}
72
+ end
73
+
74
+ Wenn /^(?:|ich )"([^"]*)" auswähle$/ do |field|
75
+ When %{I choose "#{field}"}
76
+ end
77
+
78
+ Wenn /^(?:|ich )die Datei "([^"]*)" als "([^"]*)" anhänge$/ do |path, field|
79
+ When %{I attach the file "#{path}" to "#{field}"}
80
+ end
81
+
82
+ Dann /^(?:|ich sollte |sollte (?:|ich )?)"([^"]*)" sehen$/ do |text|
83
+ Then %{I should see "#{text}"}
84
+ end
85
+
86
+ Dann /^(?:|ich sollte |sollte (?:|ich )?)"([^"]*)" innerhalb "([^"]*)" sehen$/ do |text, selector|
87
+ Then %{I should see "#{text}" within "#{selector}"}
88
+ end
89
+
90
+ Dann /^(?:|ich sollte |sollte (?:|ich )?)\/([^\/]*)\/ sehen$/ do |regexp|
91
+ Then %{I should see /#{regexp}/}
92
+ end
93
+
94
+ Dann /^(?:|ich sollte |sollte (?:|ich )?)\/([^\/]*)\/ innerhalb "([^"]*)" sehen$/ do |regexp, selector|
95
+ Then %{I should see /#{regexp}/ within "#{selector}"}
96
+ end
97
+
98
+ Dann /^(?:|ich sollte |sollte (?:|ich )?)nicht "([^"]*)" sehen$/ do |text|
99
+ Then %{I should not see "#{text}"}
100
+ end
101
+
102
+ Dann /^(?:|ich sollte |sollte (?:|ich )?)nicht "([^"]*)" innerhalb "([^"]*)" sehen$/ do |text, selector|
103
+ Then %{I should not see "#{text}" within "#{selector}"}
104
+ end
105
+
106
+ Dann /^(?:|ich sollte |sollte (?:|ich )?)nicht \/([^\/]*)\/ sehen$/ do |regexp|
107
+ Then %{I should not see /#{regexp}/}
108
+ end
109
+
110
+ Dann /^(?:|ich sollte |sollte (?:|ich )?)nicht \/([^\/]*)\/ innerhalb "([^"]*)" sehen$/ do |regexp, selector|
111
+ Then %{I should not see /#{regexp}/ within "#{selector}"}
112
+ end
113
+
114
+ Dann /^sollte das "([^"]*)" Feld "([^"]*)" enthalten$/ do |field, value|
115
+ Then %{the "#{field}" field should contain "#{value}"}
116
+ end
117
+
118
+ Dann /^sollte das "([^"]*)" Feld nicht "([^"]*)" enthalten$/ do |field, value|
119
+ Then %{the "#{field}" field should not contain "#{value}"}
120
+ end
121
+
122
+ Dann /^sollte die "([^"]*)" Checkbox angehakt sein$/ do |label|
123
+ Then %{the "#{label}" checkbox should be checked}
124
+ end
125
+
126
+ Dann /^sollte die "([^"]*)" Checkbox nicht angehakt sein$/ do |label|
127
+ Then %{the "#{label}" checkbox should not be checked}
128
+ end
129
+
130
+ Dann /^(?:|ich sollte |sollte (?:|ich )?)auf (.+) sein$/ do |page_name|
131
+ Then %{I should be on #{page_name}}
132
+ end
133
+
134
+ Dann /^zeig mir die Seite$/ do
135
+ Then %{show me the page}
136
+ end
@@ -0,0 +1,136 @@
1
+ # encoding: utf-8
2
+ <%= embed_file('support/edit_warning.txt') %>
3
+
4
+ require File.expand_path(File.join(File.dirname(__FILE__), "..", "support", "paths"))
5
+
6
+ Dado /^que estoy en (.+)$/ do |page_name|
7
+ Given %{I am on #{page_name}}
8
+ end
9
+
10
+ Cuando /^voy a (.+)$/ do |page_name|
11
+ When %{I go to #{page_name}}
12
+ end
13
+
14
+ Cuando /^apreto "([^"]*)"$/ do |button|
15
+ When %{I press "#{button}"}
16
+ end
17
+
18
+ Cuando /^clickeo "([^"]*)"$/ do |link|
19
+ When %{I follow "#{link}"}
20
+ end
21
+
22
+ Cuando /^clickeo "([^"]*)" dentro de "([^"]*)"$/ do |link, parent|
23
+ When %{I follow "#{link}" within "#{parent}"}
24
+ end
25
+
26
+ Cuando /^completo "([^"]*)" con "([^"]*)"$/ do |field, value|
27
+ When %{I fill in "#{field}" with "#{value}"}
28
+ end
29
+
30
+ Cuando /^completo "([^"]*)" para "([^"]*)"$/ do |value, field|
31
+ When %{I fill in "#{value}" for "#{field}"}
32
+ end
33
+
34
+ Cuando /^completo lo siguiente:$/ do |fields|
35
+ When %{I fill in the following:}, fields
36
+ end
37
+
38
+ Cuando /^selecciono "([^"]*)" de "([^"]*)"$/ do |value, field|
39
+ When %{I select "#{value}" from "#{field}"}
40
+ end
41
+
42
+ Cuando /^selecciono "([^"]*)" como la fecha y la hora$/ do |time|
43
+ When %{I select "#{time}" as the date and time}
44
+ end
45
+
46
+ Cuando /^selecciono "([^"]*)" como la fecha y la hora "([^"]*)"$/ do |datetime, datetime_label|
47
+ When %{I select "#{datetime}" as the "#{datetime_label}" date and time}
48
+ end
49
+
50
+ Cuando /^selecciono "([^"]*)" como la hora$/ do |time|
51
+ When %{I select "#{time}" as the time}
52
+ end
53
+
54
+ Cuando /^selecciono "([^"]*)" como la hora "([^"]*)"$/ do |time, time_label|
55
+ When %{I select "#{time}" as the "#{time_label}" time}
56
+ end
57
+
58
+ Cuando /^selecciono "([^"]*)" como la fecha$/ do |date|
59
+ When %{I select "#{date}" as the date}
60
+ end
61
+
62
+ Cuando /^selecciono "([^"]*)" como la fecha "([^"]*)"$/ do |date, date_label|
63
+ When %{I select "#{date}" as the "#{date_label}" date}
64
+ end
65
+
66
+ Cuando /^marco "([^"]*)"$/ do |field|
67
+ When %{I check "#{field}"}
68
+ end
69
+
70
+ Cuando /^desmarco "([^"]*)"$/ do |field|
71
+ When %{I uncheck "#{field}"}
72
+ end
73
+
74
+ Cuando /^elijo "([^"]*)"$/ do |field|
75
+ When %{I choose "#{field}"}
76
+ end
77
+
78
+ Cuando /^adjunto el archivo "([^"]*)" a "([^"]*)"$/ do |path, field|
79
+ When %{I attach the file "#{path}" to "#{field}"}
80
+ end
81
+
82
+ Entonces /^debería ver "([^"]*)"$/ do |text|
83
+ Then %{I should see "#{text}"}
84
+ end
85
+
86
+ Entonces /^debería ver "([^"]*)" dentro de "([^"]*)"$/ do |text, selector|
87
+ Then %{I should see "#{text}" within "#{selector}"}
88
+ end
89
+
90
+ Entonces /^debería ver \/([^\/]*)\/$/ do |regexp|
91
+ Then %{I should see /#{regexp}/}
92
+ end
93
+
94
+ Entonces /^debería ver \/([^\/]*)\/ dentro de "([^"]*)"$/ do |regexp, selector|
95
+ Then %{I should see /#{regexp}/ within "#{selector}"}
96
+ end
97
+
98
+ Entonces /^no debería ver "([^"]*)"$/ do |text|
99
+ Then %{I should not see "#{text}"}
100
+ end
101
+
102
+ Entonces /^no debería ver "([^"]*)" dentro de "([^"]*)"$/ do |text, selector|
103
+ Then %{I should not see "#{text}" within "#{selector}"}
104
+ end
105
+
106
+ Entonces /^no debería ver \/([^\/]*)\/$/ do |regexp|
107
+ Then %{I should not see /#{regexp}/}
108
+ end
109
+
110
+ Entonces /^no debería ver \/([^\/]*)\/ dentro de "([^"]*)"$/ do |regexp, selector|
111
+ Then %{I should not see /#{regexp}/ within "#{selector}"}
112
+ end
113
+
114
+ Entonces /^el campo "([^"]*)" debería contener "([^"]*)"$/ do |field, value|
115
+ Then %{the "#{field}" field should contain "#{value}"}
116
+ end
117
+
118
+ Entonces /^el campo "([^"]*)" no debería contener "([^"]*)"$/ do |field, value|
119
+ Then %{the "#{field}" field should not contain "#{value}"}
120
+ end
121
+
122
+ Entonces /^la checkbox "([^"]*)" debería estar marcada$/ do |label|
123
+ Then %{the "#{label}" checkbox should be checked}
124
+ end
125
+
126
+ Entonces /^la checkbox "([^"]*)" no debería estar marcada$/ do |label|
127
+ Then %{the "#{label}" checkbox should not be checked}
128
+ end
129
+
130
+ Entonces /^debería estar en (.+)$/ do |page_name|
131
+ Then %{I should be on #{page_name}}
132
+ end
133
+
134
+ Entonces /^mostrame la página$/ do
135
+ Then %{show me the page}
136
+ end
@@ -0,0 +1,139 @@
1
+ # encoding: utf-8
2
+ <%= embed_file('support/edit_warning.txt') %>
3
+
4
+ require File.expand_path(File.join(File.dirname(__FILE__), "..", "support", "paths"))
5
+
6
+ 前提 /^"([^"]*)"ページを表示している$/ do |page_name|
7
+ Given %{I am on #{page_name}}
8
+ end
9
+
10
+ もし /^"([^"]*)"ページを表示する$/ do |page_name|
11
+ When %{I go to #{page_name}}
12
+ end
13
+
14
+ もし /^"([^"]*)"ボタンをクリックする$/ do |button|
15
+ When %{I press "#{button}"}
16
+ end
17
+
18
+ もし /^"([^"]*)"リンクをクリックする$/ do |link|
19
+ When %{I follow "#{link}"}
20
+ end
21
+
22
+ もし /^"([^"]*)"の"([^"]*)"リンクをクリックする$/ do |parent, link|
23
+ When %{I follow "#{link}" within "#{parent}"}
24
+ end
25
+
26
+ もし /^"([^"]*)"に"([^"]*)"と入力する$/ do |field, value|
27
+ When %{I fill in "#{field}" with "#{value}"}
28
+ end
29
+
30
+ # less difference to %{I fill in "#{value}" for "#{field}"} with above in Japanese.
31
+
32
+ もし /^以下の項目を入力する:$/ do |fields|
33
+ When %{I fill in the following:}, fields
34
+ end
35
+
36
+ もし /^"([^"]*)"から"([^"]*)"を選択する$/ do |field, value|
37
+ When %{I select "#{value}" from "#{field}"}
38
+ end
39
+
40
+ もし /^日時として"([^"]*)"を選択する$/ do |time|
41
+ When %{I select "#{time}" as the date and time}
42
+ end
43
+
44
+ もし /^"([^"]*)"の日時として"([^"]*)"を選択する$/ do |datetime_label, datetime|
45
+ When %{I select "#{datetime}" as the "#{datetime_label}" date and time}
46
+ end
47
+
48
+ もし /^時間として"([^"]*)"を選択する$/ do |time|
49
+ When %{I select "#{time}" as the time}
50
+ end
51
+
52
+ もし /^"([^"]*)"の時間として"([^"]*)"を選択する$/ do |time_label, time|
53
+ When %{I select "#{time}" as the "#{time_label}" time}
54
+ end
55
+
56
+ もし /^日付として"([^"]*)"を選択する$/ do |date|
57
+ When %{I select "#{date}" as the date}
58
+ end
59
+
60
+ もし /^"([^"]*)"の日付として"([^"]*)"を選択する$/ do |date_label, date|
61
+ When %{I select "#{date}" as the "#{date_label}" date}
62
+ end
63
+
64
+ もし /^"([^"]*)"をチェックする$/ do |field|
65
+ When %{I check "#{field}"}
66
+ end
67
+
68
+ もし /^"([^"]*)"のチェックを外す$/ do |field|
69
+ When %{I uncheck "#{field}"}
70
+ end
71
+
72
+ もし /^"([^"]*)"を選択する$/ do |field|
73
+ When %{I choose "#{field}"}
74
+ end
75
+
76
+ もし /^"([^"]*)"としてファイル"([^"]*)"を選択する$/ do |field, path|
77
+ When %{I attach the file "#{path}" to "#{field}"}
78
+ end
79
+
80
+ ならば /^"([^"]*)"と表示されていること$/ do |text|
81
+ Then %{I should see "#{text}"}
82
+ end
83
+
84
+ ならば /^"([^"]*)"に"([^"]*)"と表示されていること$/ do |selector, text|
85
+ Then %{I should see "#{text}" within "#{selector}"}
86
+ end
87
+
88
+ ならば /^\/([^\/]*)\/と表示されていること$/ do |regexp|
89
+ Then %{I should see /#{regexp}/}
90
+ end
91
+
92
+ ならば /^"([^"]*)"に\/([^\/]*)\/と表示されていること$/ do |selector, regexp|
93
+ Then %{I should see \/#{regexp}\/ within "#{selector}"}
94
+ end
95
+
96
+ ならば /^"([^"]*)"と表示されていないこと$/ do |text|
97
+ Then %{I should not see "#{text}"}
98
+ end
99
+
100
+ ならば /^"([^"]*)"に"([^"]*)"と表示されていないこと$/ do |selector, text|
101
+ Then %{I should not see "#{text}" within "#{selector}"}
102
+ end
103
+
104
+ ならば /^\/([^\/]*)\/と表示されていないこと$/ do |regexp|
105
+ Then %{I should not see /#{regexp}/}
106
+ end
107
+
108
+ ならば /^"([^"]*)"に\/([^\/]*)\/と表示されていないこと$/ do |selector, regexp|
109
+ Then %{I should not see \/#{regexp}\/ within "#{selector}"}
110
+ end
111
+
112
+ ならば /^入力項目"([^"]*)"に"([^"]*)"と表示されていること$/ do |field, value|
113
+ Then %{the "#{field}" field should contain "#{value}"}
114
+ end
115
+
116
+ ならば /^入力項目"([^"]*)"に"([^"]*)"と表示されていないこと$/ do |field, value|
117
+ Then %{the "#{field}" field should not contain "#{value}"}
118
+ end
119
+
120
+ ならば /^"([^"]*)"がチェックされていること$/ do |label|
121
+ Then %{the "#{label}" checkbox should be checked}
122
+ end
123
+
124
+ ならば /^"([^"]*)"がチェックされていないこと$/ do |label|
125
+ Then %{the "#{label}" checkbox should not be checked}
126
+ end
127
+
128
+ ならば /^"([^"]*)"ページを表示していること$/ do |page_name|
129
+ Then %{I should be on #{page_name}}
130
+ end
131
+
132
+ show_me_the_page = lambda { Then %{show me the page} }
133
+
134
+ ならば /^ページを表示する$/, &show_me_the_page
135
+ ならば /^画面を目視$/, &show_me_the_page
136
+
137
+ # backword-compat for old japanese translation.
138
+ ならば /^デバッグ(?:のため)?$/, &show_me_the_page
139
+
@@ -0,0 +1,141 @@
1
+ # encoding: utf-8
2
+ <%= embed_file('support/edit_warning.txt') %>
3
+
4
+ require File.expand_path(File.join(File.dirname(__FILE__), "..", "support", "paths"))
5
+
6
+ 조건 /^(.+)페이지에 있습니다$/ do |page_name|
7
+ Given %{I am on #{page_name}}
8
+ end
9
+
10
+ 만일 /^(.+)페이지로 갑니다$/ do |page_name|
11
+ When %{I go to #{page_name}}
12
+ end
13
+
14
+ 만일 /^"([^"]*)"버튼을 누릅니다$/ do |button|
15
+ When %{I press "#{button}"}
16
+ end
17
+
18
+ 만일 /^"([^"]*)"링크를 클릭합니다$/ do |link|
19
+ When %{I follow "#{link}"}
20
+ end
21
+
22
+ 만일 /^"([^"]*)"안에 있는 "([^"]*)"링크를 클릭합니다$/ do |parent, link|
23
+ When %{I follow "#{link}" within "#{parent}"}
24
+ end
25
+
26
+ 만일 /^"([^"]*)"에 "([^"]*)"라고 적습니다$/ do |field, value|
27
+ When %{I fill in "#{field}" with "#{value}"}
28
+ end
29
+
30
+ 만일 /^"([^"]*)"라고 "([^"]*)"에 적습니다$/ do |value, field|
31
+ When %{I fill in "#{value}" for "#{field}"}
32
+ end
33
+
34
+ 만일 /^아레의 목록을 입력합니다$/ do |fields|
35
+ When %{I fill in the following:}, fields
36
+ end
37
+
38
+ 만일 /^"([^"]*)"를 "([^"]*)"으로 합니다$/ do |field, value|
39
+ When %{I select "#{value}" from "#{field}"}
40
+ end
41
+
42
+ 만일 /^날짜와 시간를 "([^"]*)"으로 합니다$/ do |time|
43
+ When %{I select "#{time}" as the date and time}
44
+ end
45
+
46
+ 만일 /^"([^"]*)"의 날짜와 시간을 "([^"]*)"으로 합니다$/ do |datetime_label, datetime|
47
+ When %{I select "#{datetime}" as the "#{datetime_label}" date and time}
48
+ end
49
+
50
+ 만일 /^시간을 "([^"]*)"으로 합니다$/ do |time|
51
+ When %{I select "#{time}" as the time}
52
+ end
53
+
54
+ 만일 /^"([^"]*)"의 시간을 "([^"]*)"으로 합니다$/ do |time_label, time|
55
+ When %{I select "#{time}" as the "#{time_label}" time}
56
+ end
57
+
58
+ 만일 /^날짜를 "([^"]*)"으로 합니다$/ do |date|
59
+ When %{I select "#{date}" as the date}
60
+ end
61
+
62
+ 만일 /^"([^"]*)"의 날짜를 "([^"]*)"으로 합니다$/ do |date_label, date|
63
+ When %{I select "#{date}" as the "#{date_label}" date}
64
+ end
65
+
66
+ 만일 /^"([^"]*)"를 체크합니다$/ do |field|
67
+ When %{I check "#{field}"}
68
+ end
69
+
70
+ 만일 /^"([^"]*)"의 체크를 해제합니다$/ do |field|
71
+ When %{I uncheck "#{field}"}
72
+ end
73
+
74
+ 만일 /^"([^"]*)"를 고릅니다$/ do |field|
75
+ When %{I choose "#{field}"}
76
+ end
77
+
78
+ 만일 /^"([^"]*)"에 "([^"]*)"파일을 첨부합니다$/ do |field, path|
79
+ When %{I attach the file "#{path}" to "#{field}"}
80
+ end
81
+
82
+ 그러면 /^"([^"]*)"가 보여야 합니다$/ do |text|
83
+ Then %{I should see "#{text}"}
84
+ end
85
+
86
+ 그러면 /^"([^"]*)"안에 "([^"]*)"가 보여야 합니다$/ do |selector, text|
87
+ Then %{I should see "#{text}" within "#{selector}"}
88
+ end
89
+
90
+ 그러면 /^\/([^\/]*)\/가 보여야 합니다$/ do |regexp|
91
+ Then %{I should see /#{regexp}/}
92
+ end
93
+
94
+ 그러면 /^"([^"]*)"안에 \/([^\/]*)\/가 보여야 합니다$/ do |selector, regexp|
95
+ Then %{I should see /#{regexp}/ within "#{selector}"}
96
+ end
97
+
98
+ 그러면 /^"([^"]*)"가 보이면 안됩니다$/ do |text|
99
+ Then %{I should not see "#{text}"}
100
+ end
101
+
102
+ 그러면 /^"([^"]*)"안에 "([^"]*)"가 보이면 안됩니다$/ do |selector, text|
103
+ Then %{I should not see "#{text}" within "#{selector}"}
104
+ end
105
+
106
+ 그러면 /^\/([^\/]*)\/가 보이면 안됩니다$/ do |regexp|
107
+ Then %{I should not see /#{regexp}/}
108
+ end
109
+
110
+ 그러면 /^"([^"]*)"안에 \/([^\/]*)\/가 보이면 안됩니다$/ do |selector, regexp|
111
+ Then %{I should not see /#{regexp}/ within "#{selector}"}
112
+ end
113
+
114
+ 그러면 /^"([^"]*)"는 "([^"]*)"이어야 합니다$/ do |field, value|
115
+ Then %{the "#{field}" field should contain "#{value}"}
116
+ end
117
+
118
+ 그러면 /^"([^"]*)"는 "([^"]*)"이면 안됩니다$/ do |field, value|
119
+ Then %{the "#{field}" field should not contain "#{value}"}
120
+ end
121
+
122
+ 그러면 /^"([^"]*)"는 체크되어 있어야 합니다$/ do |label|
123
+ Then %{the "#{label}" checkbox should be checked}
124
+ end
125
+
126
+ 그러면 /^"([^"]*)"는 체크되어 있으면 안됩니다$/ do |label|
127
+ Then %{the "#{label}" checkbox should not be checked}
128
+ end
129
+
130
+ 그러면 /^(.+)에 있어야 합니다$/ do |page_name|
131
+ Then %{I should be on #{page_name}}
132
+ end
133
+
134
+ 그러면 /^다음 쿼리들이 나와야합니다:$/ do |expected_pairs|
135
+ Then %{I should have the following query string:}
136
+ end
137
+
138
+ 그러면 /^페이지를 엽니다$/ do
139
+ Then %{show me the page}
140
+ end
141
+