public void TestCharge() { StripeToken token = CreateTestToken(); string chargeId = StripeManager.Charge(token.Id, 78.90f, "Test naked charge"); Assert.IsNotNull(chargeId); }
public void TestChargeWithCustomer() { // Arrange ICustomerEntity customer = CreateMockCustomer(); IChargeEntity charge = CreateMockCharge(); StripeToken token = CreateTestToken(customer); StripeManager.CreateCustomer(customer, token.Id); // Act - charge customer string chargeId = StripeManager.Charge(customer, charge); Assert.IsNotNull(chargeId); chargeId = StripeManager.Charge(customer, 12.34f, "Test charge with customer"); Assert.IsNotNull(chargeId); }