Skip to content

Commit

Permalink
add ineligible state for FE journey
Browse files Browse the repository at this point in the history
- when teacher does not spend at last half their hours teaching FE
  • Loading branch information
asmega committed Jul 12, 2024
1 parent de4f37b commit 1036dce
Show file tree
Hide file tree
Showing 4 changed files with 79 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,10 @@ def subject_to_problematic_actions?
def lacks_teacher_qualification_or_enrolment?
teaching_qualification == "no_not_planned"
end

def less_than_half_hours_teaching_fe?
half_teaching_hours == false
end
end
end
end
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ def ineligibility_reason
:subject_to_problematic_actions
elsif answers.lacks_teacher_qualification_or_enrolment?
:lacks_teacher_qualification_or_enrolment
elsif answers.less_than_half_hours_teaching_fe?
:must_at_least_half_hours_teaching_fe
end
end
end
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
<div class="govuk-grid-row">
<div class="govuk-grid-column-two-thirds">
<h1 class="govuk-heading-l">
You are not eligible
</h1>

<p class="govuk-body">
In order to claim a financial incentive payment, half of your timetabled teaching hours must include:
</p>

<%= govuk_list [
"a student aged 16 to 19",
"a person up to age 25 with an Education, Health and Care Plan (EHCP)",
], type: :bullet %>

<p class="govuk-body">
For more information, check the eligibility criteria for <%= govuk_link_to "levelling up premium payments for early career further education teachers", "https://www.gov.uk/guidance/levelling-up-premium-payments-for-fe-teachers", new_tab: true %>.
</p>

<p class="govuk-body">
The information entered is not stored. If you are unsure your information is correct, <%= govuk_link_to "start again", claim_path(current_journey_routing_name, "landing-page") %>.
</p>
</div>
</div>
49 changes: 49 additions & 0 deletions spec/features/further_education_payments/ineligible_paths_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -408,6 +408,55 @@
expect(page).to have_content("teach at least 2.5 hours per week")
end

scenario "when less that 50% teaching hours to FE" do
when_further_education_payments_journey_configuration_exists

visit landing_page_path(Journeys::FurtherEducationPayments::ROUTING_NAME)
expect(page).to have_link("Start now")
click_link "Start now"

expect(page).to have_content("Are you a member of staff with teaching responsibilities?")
choose "Yes"
click_button "Continue"

expect(page).to have_content("Which FE provider are you employed by?")
fill_in "Which FE provider are you employed by?", with: college.name
click_button "Continue"

expect(page).to have_content("Select the college you teach at")
choose college.name
click_button "Continue"

expect(page).to have_content("What type of contract do you have with #{college.name}?")
choose("Permanent contract")
click_button "Continue"

expect(page).to have_content("On average, how many hours per week are you timetabled to teach at #{college.name} during the current term?")
choose("More than 12 hours per week")
click_button "Continue"

expect(page).to have_content("Which academic year did you start teaching in further education (FE) in England?")
choose("September 2023 to August 2024")
click_button "Continue"

expect(page).to have_content("Which subject areas do you teach?")
check("Building and construction")
click_button "Continue"

expect(page).to have_content("FE building and construction courses goes here")
click_button "Continue"

expect(page).to have_content("FE teaching courses goes here")
click_button "Continue"

expect(page).to have_content("Are at least half of your timetabled teaching hours spent teaching 16 to 19-year-olds, including those up to age 25 with an Education, Health and Care Plan (EHCP)?")
choose "No"
click_button "Continue"

expect(page).to have_content("You are not eligible")
expect(page).to have_content("half of your timetabled teaching hours must include")
end

def when_further_education_payments_journey_configuration_exists
create(:journey_configuration, :further_education_payments)
end
Expand Down

0 comments on commit 1036dce

Please sign in to comment.