Replace expect()->regExp() with verify()->stringMatchesRegExp()
codeception/verify 2.1 removed support for expect()->regExp() so we need to replace it with verify()->stringMatchesRegExp(). [MAILPOET-5664]
This commit is contained in:
committed by
David Remer
parent
2ced2b4afa
commit
8bc4d78c68
@@ -106,7 +106,7 @@ class FormTest extends \MailPoetTest {
|
||||
$formController = new Form(ContainerWrapper::getInstance()->get(API::class), $urlHelper);
|
||||
$result = $formController->onSubmit($this->requestData);
|
||||
verify($this->subscribersRepository->findOneBy(['email' => $this->testEmail]))->notEmpty();
|
||||
expect($result)->regExp('/http.*?sample-post|http.*?\?p=\d+/i');
|
||||
verify($result)->stringMatchesRegExp('/http.*?sample-post|http.*?\?p=\d+/i');
|
||||
}
|
||||
|
||||
public function testItDoesNotSubscribeAndRedirectsBackWithErrorResponse() {
|
||||
|
Reference in New Issue
Block a user