public static void Apprentice_Stopped_And_Restarted_NonLevy() { var builder = new CohortBuilder(); builder .WithDefaultProvider() .WithNonLevyEmployer() .WithParty(Party.None) .WithApprovals(Party.Employer | Party.Provider) .WithLastAction(LastAction.Approve) .WithApprenticeshipPaymentStatus(PaymentStatus.Stopped) .WithApprenticeship(cohort => new ApprenticeshipBuilder(builder) .WithUln("1000001880") .WithStartOption(new DateTime(2018, 6, 1)) .WithStopOption(new DateTime(2018, 6, 1)) ); builder.Build(); builder = new CohortBuilder(); builder .WithDefaultProvider() .WithNonLevyEmployer() .WithParty(Party.None) .WithApprovals(Party.Employer | Party.Provider) .WithLastAction(LastAction.Approve) .WithApprenticeshipPaymentStatus(PaymentStatus.Active) .WithApprenticeship(cohort => new ApprenticeshipBuilder(builder) .WithUln("1000001880") .WithStartOption(new DateTime(2018, 6, 1)) ); builder.Build(); }
public static void Scenario_Cohort_Employer_Draft() { var builder = new CohortBuilder(); builder .WithDefaultProvider() .WithDefaultEmployer() .WithParty(Party.Employer) .WithLastAction(LastAction.None) .WithApprenticeships(10); builder.Build(); }
public static void Scenario_Cohort_Provider_ReadyForApproval() { var builder = new CohortBuilder(); builder .WithDefaultProvider() .WithDefaultEmployer() .WithParty(Party.Provider) .WithApprovals(Party.Employer) .WithLastAction(LastAction.Amend) .WithApprenticeships(10); builder.Build(); }
public static void Scenario_Transfer_Cohort_Employer_Draft() { var builder = new CohortBuilder(); builder .WithDefaultProvider() .WithNonLevyEmployer() .WithParty(Party.Employer) .WithLastAction(LastAction.None) .WithTransferSender(8194, "Mega Corp", null) .WithApprenticeships(10); builder.Build(); }
public static void Scenario_Transfer_Cohort_Rejected_By_Sender() { var builder = new CohortBuilder(); builder .WithDefaultProvider() .WithNonLevyEmployer() .WithParty(Party.Employer) .WithApprovals(Party.Employer | Party.Provider) .WithLastAction(LastAction.Approve) .WithTransferSender(8194, "Mega Corp", TransferApprovalStatus.Rejected) .WithApprenticeships(10); builder.Build(); }
public static void Scenario_Transfer_Cohort_NonLevy_Employer() { var builder = new CohortBuilder(); builder .WithDefaultProvider() .WithNonLevyEmployer() .WithParty(Party.Employer) .WithApprovals(Party.Provider) .WithLastAction(LastAction.Approve) .WithTransferSender(8194, "Mega Corp", null) .WithApprenticeship(cohort => new ApprenticeshipBuilder(builder)); builder.Build(); }
public static void Scenario_Fully_Approved_Cohort_NonLevy_WithReservation() { var builder = new CohortBuilder(); builder .WithDefaultProvider() .WithNonLevyEmployer() .WithParty(Party.None) .WithApprovals(Party.Employer | Party.Provider) .WithLastAction(LastAction.Approve) .WithApprenticeshipPaymentStatus(PaymentStatus.Active) .WithReservations() .WithApprenticeships(1); builder.Build(); }
public static void Scenario_Transfer_Cohort_Pending_With_Sender() { var builder = new CohortBuilder(); builder .WithDefaultProvider() .WithNonLevyEmployer() .WithParty(Party.TransferSender) .WithApprovals(Party.Employer | Party.Provider) .WithLastAction(LastAction.Approve) .WithApprenticeshipPaymentStatus(PaymentStatus.PendingApproval, DateTime.UtcNow) .WithTransferSender(8194, "Mega Corp", TransferApprovalStatus.Pending) .WithLastUpdatedByEmployer("Chris Foster Employer User", "*****@*****.**") .WithLastUpdatedByProvider("Chris Foster Provider User", "*****@*****.**") .WithApprenticeships(10); builder.Build(); }
public static void Cohort_Provider_Draft(int size, bool nonLevyEmployer) { var builder = new CohortBuilder(); builder .WithDefaultProvider() .WithDefaultEmployer() .WithParty(Party.Provider) .WithIsDraft(true) .WithApprenticeships(size); if (nonLevyEmployer) { builder.WithNonLevyEmployer(); } builder.Build(); }
public static void Single_Complete_NonLevy() { var builder = new CohortBuilder(); builder .WithDefaultProvider() .WithNonLevyEmployer() .WithParty(Party.None) .WithApprovals(Party.Employer | Party.Provider) .WithLastAction(LastAction.Approve) .WithIsDraft(false) .WithApprenticeshipPaymentStatus(PaymentStatus.Completed) .WithApprenticeship(cohort => new ApprenticeshipBuilder(builder) .WithStartOption(new DateTime(2019, 2, 1)) .WithCompletionOption(new DateTime(2020, 04, 01))); builder.Build(); }
public static void Scenario_NonLevy_Employer_Many_Cohorts() { CohortBuilder builder; for (var i = 0; i < 100; i++) { builder = new CohortBuilder(); builder .WithDefaultProvider() .WithNonLevyEmployer() .WithParty(Party.Employer) .WithApprovals(Party.Provider) .WithLastAction(LastAction.Approve) .WithApprenticeship(cohort => new ApprenticeshipBuilder(builder)) .WithMessages(10); builder.Build(); } }
public static void Apprentice_Stopped_NonLevy_Transfer() { var builder = new CohortBuilder(); builder .WithDefaultProvider() .WithNonLevyEmployer() .WithParty(Party.None) .WithApprovals(Party.Employer | Party.Provider | Party.TransferSender) .WithLastAction(LastAction.Approve) .WithTransferSender(8194, "Mega Corp", TransferApprovalStatus.Approved) .WithApprenticeshipPaymentStatus(PaymentStatus.Cancelled) .WithApprenticeship(cohort => new ApprenticeshipBuilder(builder) .WithStartOption(new DateTime(2019, 6, 1)) .WithStopOption(new DateTime(2020, 3, 1)) ); builder.Build(); }
public static void Apprentice_Stopped_WithChangeOfPartyRequest_NonLevy() { var builder = new CohortBuilder(); builder .WithDefaultProvider() .WithNonLevyEmployer() .WithParty(Party.None) .WithApprovals(Party.Employer | Party.Provider) .WithLastAction(LastAction.Approve) .WithApprenticeshipPaymentStatus(PaymentStatus.Cancelled) .WithApprenticeship(cohort => new ApprenticeshipBuilder(builder) .WithStartOption(new DateTime(2019, 6, 1)) .WithStopOption(new DateTime(2020, 3, 1)) .WithChangeOfPartyRequest() ); builder.Build(); }
public static void Apprentice_Stopped_NonLevy_FundingCapChange() { var course = new TrainingCourse { Id = "176", Title = "Accident Repair Technician" }; var builder = new CohortBuilder(); builder .WithDefaultProvider() .WithNonLevyEmployer() .WithParty(Party.None) .WithApprovals(Party.Employer | Party.Provider) .WithLastAction(LastAction.Approve) .WithApprenticeshipPaymentStatus(PaymentStatus.Cancelled) .WithApprenticeship(cohort => new ApprenticeshipBuilder(builder) .WithStartOption(new DateTime(2018, 1, 1)) .WithStopOption(new DateTime(2020, 3, 1)) .WithTrainingCourse(course) .WithCost(10000) ); builder.Build(); }
public static void Apprentice_Stopped_NonLevy_Expired() { var course = new TrainingCourse { Id = "403-2-1", Title = "Food and Drink: Meat and Poultry Industry Skills" }; var builder = new CohortBuilder(); builder .WithDefaultProvider() .WithNonLevyEmployer() .WithParty(Party.None) .WithApprovals(Party.Employer | Party.Provider) .WithLastAction(LastAction.Approve) .WithApprenticeshipPaymentStatus(PaymentStatus.Cancelled) .WithApprenticeship(cohort => new ApprenticeshipBuilder(builder) .WithStartOption(new DateTime(2017, 5, 1)) .WithEndOption(new DateTime(2021, 1, 1)) .WithStopOption(new DateTime(2019, 1, 1)) .WithTrainingCourse(course) ); builder.Build(); }