From 76f646fc81bdf02ffe42067dcbc0460c9649d635 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Benjamin=20Beganovi=C4=87?= Date: Fri, 24 Sep 2021 23:23:16 +0200 Subject: [PATCH] Tests: Successful payments --- .../ClientPortal/Gateways/Mollie/KBCTest.php | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/tests/Browser/ClientPortal/Gateways/Mollie/KBCTest.php b/tests/Browser/ClientPortal/Gateways/Mollie/KBCTest.php index a8ec810fe7d0..584f5a286885 100644 --- a/tests/Browser/ClientPortal/Gateways/Mollie/KBCTest.php +++ b/tests/Browser/ClientPortal/Gateways/Mollie/KBCTest.php @@ -37,4 +37,21 @@ class KBCTest extends DuskTestCase ->auth(); }); } + + public function testSuccessfulPayment(): void + { + $this->browse(function (Browser $browser) { + $browser + ->visitRoute('client.invoices.index') + ->click('@pay-now') + ->press('Pay Now') + ->clickLink('Undefined.') + ->waitForText('Test profile') + ->press('CBC') + ->radio('final_state', 'paid') + ->press('Continue') + ->waitForText('Details of the payment') + ->assertSee('Completed'); + }); + } } \ No newline at end of file