'email' => 'foo-test@test.de',
'storefrontUrl' => 'http://localhost',
] );
static::
assertEquals(200,
$this->browser->
getResponse()->
getStatusCode(),
$this->browser->
getResponse()->
getContent() ?: ''
);
/** @var CustomerAccountRecoverRequestEvent $caughtEvent */
static::
assertInstanceOf(CustomerAccountRecoverRequestEvent::
class,
$caughtEvent);
static::
assertStringStartsWith('http://localhost/test/rec/password/',
$caughtEvent->
getResetUrl());
static::
assertStringEndsWith('/?somethingSpecial=1',
$caughtEvent->
getResetUrl());
} /**
* @return array<array{0: array{domain: string, expectDomain: string}}>
*/
public static function sendMailWithDomainAndLeadingSlashProvider(): array
{ return [ // test without leading slash
[ ['domain' => 'http://my-evil-page', 'expectDomain' => 'http://my-evil-page'
],
],