mirror of
https://github.com/nothingworksinc/ticketbeast.git
synced 2026-02-03 20:48:34 +00:00
158 - Exchanging Tokens
This commit is contained in:
@@ -26,7 +26,18 @@ class ConnectWithStripeTest extends DuskTestCase
|
||||
->assertQueryStringHas('response_type', 'code')
|
||||
->assertQueryStringHas('scope', 'read_write')
|
||||
->assertQueryStringHas('client_id', config('services.stripe.client_id'))
|
||||
;
|
||||
->clickLink("Skip this account form")
|
||||
->assertRouteIs('backstage.concerts.index');
|
||||
|
||||
tap($user->fresh(), function ($user) {
|
||||
$this->assertNotNull($user->stripe_account_id);
|
||||
$this->assertNotNull($user->stripe_access_token);
|
||||
|
||||
$connectedAccount = \Stripe\Account::retrieve(null, [
|
||||
'api_key' => $user->stripe_access_token
|
||||
]);
|
||||
$this->assertEquals($connectedAccount->id, $user->stripe_account_id);
|
||||
});
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user