Exemplo n.º 1
0
        public void CreateAccount()
        {
            var bankAccountInfo      = TestAccountData.GetBankAccountData();
            var userBusinessInfo     = TestAccountData.GetBusinessData();
            var accountPersonalInfo  = TestAccountData.GetUserPersonalData();
            var threatRiskData       = TestAccountData.GetThreatRiskData();
            var significantOwnerData = TestAccountData.GetSignificantOwnerData();
            var ownersInfo           = TestAccountData.GetBeneficialOwnerData();
            var creditCardInfo       = TestAccountData.GetCreditCardData();
            var achInfo                  = TestAccountData.GetACHData();
            var mailingAddressInfo       = TestAccountData.GetMailingAddress();
            var secondaryBankInformation = TestAccountData.GetSecondaryBankAccountData();
            var deviceData               = TestAccountData.GetDeviceData(1, false);

            var response = _service.CreateAccount()
                           .WithBankAccountData(bankAccountInfo)
                           .WithBusinessData(userBusinessInfo)
                           .WithUserPersonalData(accountPersonalInfo)
                           .WithThreatRiskData(threatRiskData)
                           .WithSignificantOwnerData(significantOwnerData)
                           .WithBeneficialOwnerData(ownersInfo)
                           .WithCreditCardData(creditCardInfo)
                           .WithACHData(achInfo)
                           .WithMailingAddress(mailingAddressInfo)
                           .WithSecondaryBankAccountData(secondaryBankInformation)
                           .WithDeviceData(deviceData)
                           .WithTimeZone("ET")
                           .Execute();

            Assert.IsNotNull(response);
            Assert.AreEqual("00", response.ResponseCode);
            Assert.IsNotNull(response.PayFacData.AccountNumber);
            Assert.IsNotNull(response.PayFacData.Password);
            Assert.IsNotNull(response.PayFacData.SourceEmail);
        }