-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of https://github.com/SkillsFundingAgency/das-e…
…mployerapprenticeshipsservice into CON-1712-TechDept
- Loading branch information
Showing
67 changed files
with
905 additions
and
1,216 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
92 changes: 0 additions & 92 deletions
92
...rollers/EmployerTeamControllerTests/WhenCallToActionToggleIsEnabled/WhenFundsToReserve.cs
This file was deleted.
Oops, something went wrong.
68 changes: 68 additions & 0 deletions
68
...trollerTests/WhenCallToActionToggleIsEnabled/WhenIChooseIIfIKnowApprenticehipStartDate.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
using System.Web.Mvc; | ||
using Moq; | ||
using NUnit.Framework; | ||
using SFA.DAS.Authentication; | ||
using SFA.DAS.Authorization.Services; | ||
using SFA.DAS.EmployerAccounts.Interfaces; | ||
using SFA.DAS.EmployerAccounts.Web.Controllers; | ||
using SFA.DAS.EmployerAccounts.Web.Helpers; | ||
using SFA.DAS.EmployerAccounts.Web.Orchestrators; | ||
using SFA.DAS.EmployerAccounts.Web.ViewModels; | ||
|
||
namespace SFA.DAS.EmployerAccounts.Web.UnitTests.Controllers.EmployerTeamControllerTests.WhenCallToActionToggleIsEnabled | ||
{ | ||
public class WhenIChooseIIfIKnowApprenticehipStartDate | ||
{ | ||
private EmployerTeamController _controller; | ||
|
||
private Mock<IAuthenticationService> mockAuthenticationService; | ||
private Mock<IMultiVariantTestingService> mockMultiVariantTestingService; | ||
private Mock<ICookieStorageService<FlashMessageViewModel>> mockCookieStorageService; | ||
private Mock<EmployerTeamOrchestrator> mockEmployerTeamOrchestrator; | ||
|
||
[SetUp] | ||
public void Arrange() | ||
{ | ||
mockAuthenticationService = new Mock<IAuthenticationService>(); | ||
mockMultiVariantTestingService = new Mock<IMultiVariantTestingService>(); | ||
mockCookieStorageService = new Mock<ICookieStorageService<FlashMessageViewModel>>(); | ||
mockEmployerTeamOrchestrator = new Mock<EmployerTeamOrchestrator>(); | ||
|
||
_controller = new EmployerTeamController( | ||
mockAuthenticationService.Object, | ||
mockMultiVariantTestingService.Object, | ||
mockCookieStorageService.Object, | ||
mockEmployerTeamOrchestrator.Object); | ||
} | ||
|
||
[Test] | ||
public void IfIChooseYesIContinueTheJourney() | ||
{ | ||
//Act | ||
var result = _controller.TriageWillApprenticeshipTrainingStart(new TriageViewModel {TriageOption = TriageOptions.Yes}) as RedirectToRouteResult; | ||
|
||
//Assert | ||
Assert.AreEqual(ControllerConstants.TriageApprenticeForExistingEmployeeActionName, result.RouteValues["Action"]); | ||
} | ||
|
||
[Test] | ||
public void IfIChooseNoICannotSetupAnApprentice() | ||
{ | ||
//Act | ||
var result = _controller.TriageWillApprenticeshipTrainingStart(new TriageViewModel { TriageOption = TriageOptions.No }) as RedirectToRouteResult; | ||
|
||
//Assert | ||
Assert.AreEqual(ControllerConstants.TriageYouCannotSetupAnApprenticeshipYetStartDateActionName, result.RouteValues["Action"]); | ||
} | ||
|
||
[Test] | ||
public void IfIChooseDontKnowICannotSetupAnApprentice() | ||
{ | ||
//Act | ||
var result = _controller.TriageWillApprenticeshipTrainingStart(new TriageViewModel { TriageOption = TriageOptions.Unknown }) as RedirectToRouteResult; | ||
|
||
//Assert | ||
Assert.AreEqual(ControllerConstants.TriageYouCannotSetupAnApprenticeshipYetApproximateStartDateActionName, result.RouteValues["Action"]); | ||
} | ||
} | ||
} |
Oops, something went wrong.