Changeset View
Changeset View
Standalone View
Standalone View
src/tests/Browser/Reseller/PaymentMollieTest.php
Show First 20 Lines • Show All 77 Lines • ▼ Show 20 Lines | public function testPayment(): void | ||||
->assertSeeIn('#amount + span + .invalid-feedback', 'The amount must be a number.') | ->assertSeeIn('#amount + span + .invalid-feedback', 'The amount must be a number.') | ||||
// Submit valid data | // Submit valid data | ||||
->type('@body #amount', '12.34') | ->type('@body #amount', '12.34') | ||||
// Note we use double click to assert it does not create redundant requests | // Note we use double click to assert it does not create redundant requests | ||||
->click('@button-action') | ->click('@button-action') | ||||
->click('@button-action'); | ->click('@button-action'); | ||||
}) | }) | ||||
->on(new PaymentMollie()) | ->on(new PaymentMollie()) | ||||
->assertSeeIn('@title', \config('app.name') . ' Payment') | ->assertSeeIn('@title', $user->tenant->title . ' Payment') | ||||
->assertSeeIn('@amount', 'CHF 12.34'); | ->assertSeeIn('@amount', 'CHF 12.34'); | ||||
$this->assertSame(1, $wallet->payments()->count()); | $this->assertSame(1, $wallet->payments()->count()); | ||||
// Looks like the Mollie testing mode is limited. | // Looks like the Mollie testing mode is limited. | ||||
// We'll select credit card method and mark the payment as paid | // We'll select credit card method and mark the payment as paid | ||||
// We can't do much more, we have to trust Mollie their page works ;) | // We can't do much more, we have to trust Mollie their page works ;) | ||||
Show All 22 Lines |