Пример #1
0
        public EmployerIncentivesApiBuilder WithBankingDetails()
        {
            var data = new TestData.Account.WithInitialApplicationAndBankingDetails();

            _server
            .Given(
                Request
                .Create()
                .WithPath($"/email/bank-details-reminder")
                .UsingPost()
                )
            .RespondWith(
                Response.Create()
                .WithStatusCode(HttpStatusCode.OK)
                .WithHeader("Content-Type", "application/json")
                .WithBody(string.Empty));

            _server
            .Given(
                Request
                .Create()
                .WithPath(x => x.Contains($"accounts/{data.AccountId}/applications/") && x.Contains("/bankingDetails"))
                .WithParam("hashedAccountId", $"{data.HashedAccountId}")
                .UsingGet()
                )
            .RespondWith(
                Response.Create()
                .WithBody(JsonConvert.SerializeObject(data.BankingDetails, TestHelper.DefaultSerialiserSettings))
                .WithStatusCode(HttpStatusCode.OK));

            return(this);
        }
Пример #2
0
        public ReadyToEnterBankDetailsSteps(TestContext testContext) : base(testContext)
        {
            _testContext = testContext;
            _fixture     = new Fixture();
            _data        = new TestData.Account.WithInitialApplicationAndBankingDetails();

            _testContext.TestDataStore.Add("HashedAccountId", _data.HashedAccountId);
            _testContext.AddOrReplaceClaim(EmployerClaimTypes.Account, _data.HashedAccountId);
        }
 public CompleteApplicationSteps(TestContext testContext) : base(testContext)
 {
     _testContext = testContext;
     _testdata    = new TestData.Account.WithInitialApplicationAndBankingDetails();
     _fixture     = new Fixture();
 }
 public AmendBankDetailsSteps(TestContext testContext) : base(testContext)
 {
     _testContext = testContext;
     _testData    = new TestData.Account.WithInitialApplicationAndBankingDetails();
 }