Skip to content

Commit b634b2a

Browse files
committed
MAGETWO-49820: Can't register customer if customer attribute is required but not visible (#3457)
1 parent 500177a commit b634b2a

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerInvalidEmail.php

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66

77
namespace Magento\Customer\Test\Constraint;
88

9-
use Magento\Customer\Test\Fixture\Customer;
109
use Magento\Customer\Test\Page\Adminhtml\CustomerIndexNew;
1110
use Magento\Mtf\Constraint\AbstractConstraint;
1211

@@ -16,19 +15,18 @@
1615
*/
1716
class AssertCustomerInvalidEmail extends AbstractConstraint
1817
{
19-
const ERROR_EMAIL_MESSAGE = 'Please correct this email address: "%email%".';
18+
const ERROR_EMAIL_MESSAGE = '"Email" is not a valid hostname.';
2019

2120
/**
2221
* Assert that error message "Please correct this email address: "%email%"." is displayed
2322
* after customer with invalid email save
2423
*
25-
* @param Customer $customer
2624
* @param CustomerIndexNew $pageCustomerIndexNew
2725
* @return void
2826
*/
29-
public function processAssert(Customer $customer, CustomerIndexNew $pageCustomerIndexNew)
27+
public function processAssert(CustomerIndexNew $pageCustomerIndexNew)
3028
{
31-
$expectMessage = str_replace('%email%', $customer->getEmail(), self::ERROR_EMAIL_MESSAGE);
29+
$expectMessage = self::ERROR_EMAIL_MESSAGE;
3230
$actualMessage = $pageCustomerIndexNew->getMessagesBlock()->getErrorMessage();
3331

3432
\PHPUnit_Framework_Assert::assertEquals(

0 commit comments

Comments
 (0)