From c014f6fb956d3cf70adecd245b0b194160cb9829 Mon Sep 17 00:00:00 2001 From: Avin Hurry Date: Tue, 21 May 2024 15:19:19 +0100 Subject: [PATCH] [1675] Make tests pass The accredited provider should exist in the current cycle as an accredited provider. This validation was put in place due to ITT reform where some accredited providers lost their accredidation at the begining of the 2024 cycle. --- spec/features/publish/courses/new_tda_course_spec.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/spec/features/publish/courses/new_tda_course_spec.rb b/spec/features/publish/courses/new_tda_course_spec.rb index 67a63f2e8f..1500e198c9 100644 --- a/spec/features/publish/courses/new_tda_course_spec.rb +++ b/spec/features/publish/courses/new_tda_course_spec.rb @@ -141,7 +141,8 @@ def given_i_am_authenticated_as_a_school_direct_provider_user recruitment_cycle = create(:recruitment_cycle, year: 2025) @user = create(:user, providers: [build(:provider, recruitment_cycle:, provider_type: 'lead_school', sites: [build(:site), build(:site)], study_sites: [build(:site, :study_site), build(:site, :study_site)])]) @provider = @user.providers.first - @accredited_provider = create(:provider, :accredited_provider, recruitment_cycle:) + create(:provider, :accredited_provider, provider_code: '1BJ') + @accredited_provider = create(:provider, :accredited_provider, provider_code: '1BJ', recruitment_cycle:) @provider.accrediting_provider_enrichments = [] @provider.accrediting_provider_enrichments << AccreditingProviderEnrichment.new( {