Skip to content

Commit e6a58ab

Browse files
committed
WIP
1 parent 5eaed09 commit e6a58ab

File tree

1 file changed

+62
-1
lines changed

1 file changed

+62
-1
lines changed

spec/system/eligibility_with_prioritisation_spec.rb renamed to spec/system/eligibility_with_referee_email_domain_spec.rb

Lines changed: 62 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,13 @@
66
type: :system do
77
around do |example|
88
FeatureFlags::FeatureFlag.activate(:prioritisation)
9+
FeatureFlags::FeatureFlag.activate(:email_domains_for_referees)
910

1011
given_countries_exist
1112
example.run
1213

1314
FeatureFlags::FeatureFlag.deactivate(:prioritisation)
15+
FeatureFlags::FeatureFlag.deactivate(:email_domains_for_referees)
1416
end
1517

1618
it "happy path" do
@@ -30,6 +32,9 @@
3032
then_i_see_the(:eligibility_work_experience_page)
3133

3234
when_i_have_more_than_20_months_work_experience
35+
then_i_see_the(:eligibility_work_experience_referee_page)
36+
37+
when_i_have_valid_work_experience_referee
3338
then_i_see_the(:eligibility_misconduct_page)
3439

3540
when_i_dont_have_a_misconduct_record
@@ -66,6 +71,9 @@
6671
then_i_see_the(:eligibility_work_experience_page)
6772

6873
when_i_have_under_9_months_work_experience
74+
then_i_see_the(:eligibility_work_experience_referee_page)
75+
76+
when_i_dont_have_valid_work_experience_referee
6977
then_i_see_the(:eligibility_misconduct_page)
7078

7179
when_i_have_a_misconduct_record
@@ -80,6 +88,7 @@
8088
and_i_see_the_ineligible_qualification_text_with_eligible_country
8189
and_i_see_the_ineligible_teach_children_text
8290
and_i_see_the_ineligible_work_experience_text
91+
and_i_see_the_ineligible_work_experience_referee_text
8392
and_i_see_the_ineligible_misconduct_text
8493
end
8594

@@ -114,10 +123,16 @@
114123
when_i_have_a_degree
115124
then_i_see_the(:eligibility_work_experience_page)
116125

117-
when_i_visit_the(:eligibility_misconduct_page)
126+
when_i_visit_the(:eligibility_work_experience_referee_page)
118127
then_i_see_the(:eligibility_work_experience_page)
119128

120129
when_i_have_more_than_20_months_work_experience
130+
then_i_see_the(:eligibility_work_experience_referee_page)
131+
132+
when_i_visit_the(:eligibility_misconduct_page)
133+
then_i_see_the(:eligibility_work_experience_referee_page)
134+
135+
when_i_have_valid_work_experience_referee
121136
then_i_see_the(:eligibility_misconduct_page)
122137

123138
when_i_visit_the(:eligibility_work_experience_in_england_page)
@@ -139,6 +154,40 @@
139154
then_i_see_the(:eligibility_eligible_page)
140155
end
141156

157+
it "happy path when selecting country with reduced evidence required" do
158+
when_i_visit_the(:eligibility_start_page)
159+
then_i_see_the(:eligibility_start_page)
160+
161+
when_i_press_start_now
162+
then_i_see_the(:eligibility_country_page)
163+
164+
when_i_select_a_reduced_evidence_required_country
165+
then_i_see_the(:eligibility_qualification_page)
166+
167+
when_i_have_a_qualification
168+
then_i_see_the(:eligibility_degree_page)
169+
170+
when_i_have_a_degree
171+
then_i_see_the(:eligibility_work_experience_page)
172+
173+
when_i_have_more_than_20_months_work_experience
174+
then_i_see_the(:eligibility_misconduct_page)
175+
176+
when_i_dont_have_a_misconduct_record
177+
then_i_see_the(:eligibility_work_experience_in_england_page)
178+
179+
when_i_have_work_experience_in_england
180+
then_i_see_the(:eligibility_teach_children_page)
181+
182+
when_i_can_teach_children
183+
then_i_see_the(:eligibility_eligible_page)
184+
185+
when_i_visit_the(:eligibility_start_page)
186+
then_i_see_the(:eligibility_start_page)
187+
when_i_press_start_now
188+
then_i_have_two_eligibility_checks
189+
end
190+
142191
it "happy path when filtering by country requiring qualification for subject without England work" do
143192
when_i_visit_the(:eligibility_start_page)
144193
then_i_see_the(:eligibility_start_page)
@@ -156,6 +205,9 @@
156205
then_i_see_the(:eligibility_work_experience_page)
157206

158207
when_i_have_more_than_20_months_work_experience
208+
then_i_see_the(:eligibility_work_experience_referee_page)
209+
210+
when_i_have_valid_work_experience_referee
159211
then_i_see_the(:eligibility_misconduct_page)
160212

161213
when_i_dont_have_a_misconduct_record
@@ -188,6 +240,9 @@
188240
then_i_see_the(:eligibility_work_experience_page)
189241

190242
when_i_have_more_than_20_months_work_experience
243+
then_i_see_the(:eligibility_work_experience_referee_page)
244+
245+
when_i_have_valid_work_experience_referee
191246
then_i_see_the(:eligibility_misconduct_page)
192247

193248
when_i_dont_have_a_misconduct_record
@@ -220,6 +275,9 @@
220275
then_i_see_the(:eligibility_work_experience_page)
221276

222277
when_i_have_more_than_20_months_work_experience
278+
then_i_see_the(:eligibility_work_experience_referee_page)
279+
280+
when_i_have_valid_work_experience_referee
223281
then_i_see_the(:eligibility_misconduct_page)
224282

225283
when_i_dont_have_a_misconduct_record
@@ -252,6 +310,9 @@
252310
then_i_see_the(:eligibility_work_experience_page)
253311

254312
when_i_have_more_than_20_months_work_experience
313+
then_i_see_the(:eligibility_work_experience_referee_page)
314+
315+
when_i_have_valid_work_experience_referee
255316
then_i_see_the(:eligibility_misconduct_page)
256317

257318
when_i_dont_have_a_misconduct_record

0 commit comments

Comments
 (0)