public async Task WhenCustomDraftSkillsHaveBeenAdded_ShouldBeOrderedByTheirPrefix() { var fixture = new SkillsOrchestratorTestsFixture(); var draftSkill1 = "Draft1"; var draftSkill2 = "Draft2"; var draftSkill3 = "Draft3"; fixture .WithSelectedSkills(new string[] { }) .Setup(); var vacancyRouteModel = new VacancyRouteModel { EmployerAccountId = fixture.Vacancy.EmployerAccountId, VacancyId = fixture.Vacancy.Id }; var skillsViewModel = await fixture.GetSkillsViewModelAsync(vacancyRouteModel, new string[] { "2-" + draftSkill2, "3-" + draftSkill3, "1-" + draftSkill1 }); fixture.VerifyColumn2CheckboxesItemSelected(skillsViewModel, draftSkill1, 8); fixture.VerifyColumn1CheckboxesItemSelected(skillsViewModel, draftSkill2, 9); fixture.VerifyColumn2CheckboxesItemSelected(skillsViewModel, draftSkill3, 9); }
public async Task WhenCustomDraftSkillsAddedAndBaseSkillSelected_ShouldBeAddedToAlternateColumnsStartingWithColumn2() { var fixture = new SkillsOrchestratorTestsFixture(); var draftSkill1 = "Draft1"; var draftSkill2 = "Draft2"; var draftSkill3 = "Draft3"; fixture .WithSelectedSkills(new string[] { }) .Setup(); var vacancyRouteModel = new VacancyRouteModel { EmployerAccountId = fixture.Vacancy.EmployerAccountId, VacancyId = fixture.Vacancy.Id }; var skillsViewModel = await fixture.GetSkillsViewModelAsync(vacancyRouteModel, new string[] { "1-" + draftSkill1, "Patience", "2-" + draftSkill2, "3-" + draftSkill3 }); fixture.VerifyColumn2CheckboxesItemSelected(skillsViewModel, draftSkill1, 8); fixture.VerifyColumn1CheckboxesItemSelected(skillsViewModel, draftSkill2, 9); fixture.VerifyColumn2CheckboxesItemSelected(skillsViewModel, draftSkill3, 9); }
public async Task WhenCustomeDraftSkillsAdded_ShouldBeAddedToAlternateColumnsStartingWithColumn2() { var fixture = new SkillsOrchestratorTestsFixture(); var draftSkill1 = "Draft1"; var draftSkill2 = "Draft2"; var draftSkill3 = "Draft3"; fixture .WithSelectedSkills(new string[] { }) .Setup(); var vacancyRouteModel = new VacancyRouteModel { Ukprn = fixture.Vacancy.TrainingProvider.Ukprn.Value, VacancyId = fixture.Vacancy.Id }; var skillsViewModel = await fixture.GetSkillsViewModelAsync(vacancyRouteModel, new string[] { "1-" + draftSkill1, "2-" + draftSkill2, "3-" + draftSkill3 }); fixture.VerifyColumn2CheckboxesItemSelected(skillsViewModel, draftSkill1, 8); fixture.VerifyColumn1CheckboxesItemSelected(skillsViewModel, draftSkill2, 9); fixture.VerifyColumn2CheckboxesItemSelected(skillsViewModel, draftSkill3, 9); }
public async Task WhenMultipleCustomSkillsSaved_ShouldReturnTheCustomSkillsInAlternateColumnsStaringWithColumn2() { var fixture = new SkillsOrchestratorTestsFixture(); var customSkill1 = "Custom1"; var customSkill2 = "Custom2"; var customSkill3 = "Custom3"; fixture .WithSelectedSkills(new string[] { customSkill1, customSkill2, customSkill3 }) .Setup(); var vacancyRouteModel = new VacancyRouteModel { EmployerAccountId = fixture.Vacancy.EmployerAccountId, VacancyId = fixture.Vacancy.Id }; var skillsViewModel = await fixture.GetSkillsViewModelAsync(vacancyRouteModel); fixture.VerifyColumn2CheckboxesItemSelected(skillsViewModel, customSkill1, 8); fixture.VerifyColumn1CheckboxesItemSelected(skillsViewModel, customSkill2, 9); fixture.VerifyColumn2CheckboxesItemSelected(skillsViewModel, customSkill3, 9); }
public async Task WhenCustomSkillHasBeenSaved_ShouldReturnCustomSkillsSelectedInLastItemInSecondColumn() { var fixture = new SkillsOrchestratorTestsFixture(); var customSkill = "Custom1"; fixture .WithSelectedSkills(new string[] { customSkill }) .Setup(); var vacancyRouteModel = new VacancyRouteModel { EmployerAccountId = fixture.Vacancy.EmployerAccountId, VacancyId = fixture.Vacancy.Id }; var skillsViewModel = await fixture.GetSkillsViewModelAsync(vacancyRouteModel); fixture.VerifyColumn2CheckboxesItemSelected(skillsViewModel, customSkill, 8); }
public async Task WhenCustomDraftSkillHasBeenAdded_ShouldBeAddedToColumn2() { var fixture = new SkillsOrchestratorTestsFixture(); var draftSkill = "Draft1"; fixture .WithSelectedSkills(new string[] { }) .Setup(); var vacancyRouteModel = new VacancyRouteModel { EmployerAccountId = fixture.Vacancy.EmployerAccountId, VacancyId = fixture.Vacancy.Id }; var skillsViewModel = await fixture.GetSkillsViewModelAsync(vacancyRouteModel, new string[] { "1-" + draftSkill }); fixture.VerifyColumn2CheckboxesItemSelected(skillsViewModel, draftSkill, 8); }