public void TestAddPayFacCredit() { var payFacCredit = new payFacCredit(); payFacCredit.fundingSubmerchantId = "123456"; payFacCredit.fundsTransferId = "123467"; payFacCredit.amount = 107L; batchRequest.addPayFacCredit(payFacCredit); Assert.AreEqual(1, batchRequest.getNumPayFacCredit()); Assert.AreEqual(107L, batchRequest.getPayFacCreditAmount()); Assert.AreEqual("\r\n<payFacCredit reportGroup=\"Default Report Group\">\r\n<fundingSubmerchantId>123456</fundingSubmerchantId>\r\n<fundsTransferId>123467</fundsTransferId>\r\n<amount>107</amount>\r\n</payFacCredit>", payFacCredit.Serialize()); mockCnpFile.Verify(cnpFile => cnpFile.createRandomFile(It.IsAny <string>(), It.IsAny <string>(), It.IsAny <string>(), mockCnpTime.Object)); mockCnpFile.Verify(cnpFile => cnpFile.AppendLineToFile(mockFilePath, payFacCredit.Serialize())); }
public void testAddPayFacCredit() { var payFacCredit = new payFacCredit(); payFacCredit.fundingSubmerchantId = "123456"; payFacCredit.fundsTransferId = "123467"; payFacCredit.amount = 107L; batchRequest.addPayFacCredit(payFacCredit); Assert.AreEqual(1, batchRequest.getNumPayFacCredit()); Assert.AreEqual(107L, batchRequest.getPayFacCreditAmount()); mockLitleFile.Verify( litleFile => litleFile.createRandomFile(It.IsAny <string>(), It.IsAny <string>(), It.IsAny <string>(), mockLitleTime.Object)); mockLitleFile.Verify(litleFile => litleFile.AppendLineToFile(mockFilePath, payFacCredit.Serialize())); }
public void testAddPayFacCredit() { var payFacCredit = new payFacCredit(); payFacCredit.fundingSubmerchantId = "123456"; payFacCredit.fundsTransferId = "123467"; payFacCredit.amount = 107L; batchRequest.addPayFacCredit(payFacCredit); Assert.AreEqual(1, batchRequest.getNumPayFacCredit()); Assert.AreEqual(107L, batchRequest.getPayFacCreditAmount()); mockLitleFile.Verify( litleFile => litleFile.createRandomFile(It.IsAny<string>(), It.IsAny<string>(), It.IsAny<string>(), mockLitleTime.Object)); mockLitleFile.Verify(litleFile => litleFile.AppendLineToFile(mockFilePath, payFacCredit.Serialize())); }