mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-06-03 15:24:34 -04:00
Pay with new credit card test
This commit is contained in:
parent
d70e7dfc36
commit
1b0ff21f20
@ -36,4 +36,30 @@ class CreditCardTest extends DuskTestCase
|
||||
->auth();
|
||||
});
|
||||
}
|
||||
|
||||
public function testPayWithNewCreditCard()
|
||||
{
|
||||
$this->browse(function (Browser $browser) {
|
||||
$browser
|
||||
->visitRoute('client.invoices.index')
|
||||
->click('@pay-now')
|
||||
->press('Pay Now')
|
||||
->clickLink('Credit Card')
|
||||
->pause(5000)
|
||||
->withinFrame('iframe[name=cardNumber-input]', function (Browser $browser) {
|
||||
$browser->type('#cardNumber', '4242424242424242');
|
||||
})
|
||||
->withinFrame('iframe[name=cardHolder-input]', function (Browser $browser) {
|
||||
$browser->type('#cardHolder', 'Invoice Ninja Test Suite');
|
||||
})
|
||||
->withinFrame('iframe[name=expiryDate-input]', function (Browser $browser) {
|
||||
$browser->type('#expiryDate', '12/29');
|
||||
})
|
||||
->withinFrame('iframe[name=verificationCode-input]', function (Browser $browser) {
|
||||
$browser->type('#verificationCode', '100');
|
||||
})
|
||||
->press('Pay Now')
|
||||
->waitForText('Details of the payment', 60);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user