-
Notifications
You must be signed in to change notification settings - Fork 9.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
4c71a22
commit b159dfb
Showing
3 changed files
with
46 additions
and
47 deletions.
There are no files selected for viewing
46 changes: 0 additions & 46 deletions
46
...unctional/tests/app/Magento/User/Test/Constraint/AssertAccessTokensErrorRevokeMessage.php
This file was deleted.
Oops, something went wrong.
45 changes: 45 additions & 0 deletions
45
...nctional/tests/app/Magento/User/Test/Constraint/AssertAccessTokensSuccessfullyRevoked.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
<?php | ||
/** | ||
* Copyright © Magento, Inc. All rights reserved. | ||
* See COPYING.txt for license details. | ||
*/ | ||
|
||
namespace Magento\User\Test\Constraint; | ||
|
||
use Magento\User\Test\Page\Adminhtml\UserEdit; | ||
use Magento\Mtf\Constraint\AbstractConstraint; | ||
|
||
/** | ||
* Assert that success message appears after click on 'Force Sing-In' button. | ||
*/ | ||
class AssertAccessTokensSuccessfullyRevoked extends AbstractConstraint | ||
{ | ||
/** | ||
* User revoke tokens success message. | ||
*/ | ||
const SUCCESS_MESSAGE = 'You have revoked the user\'s tokens.'; | ||
|
||
/** | ||
* Assert that success message appears after click on 'Force Sing-In' button. | ||
* | ||
* @param UserEdit $userEdit | ||
* @return void | ||
*/ | ||
public function processAssert(UserEdit $userEdit): void | ||
{ | ||
\PHPUnit\Framework\Assert::assertEquals( | ||
self::SUCCESS_MESSAGE, | ||
$userEdit->getMessagesBlock()->getSuccessMessage() | ||
); | ||
} | ||
|
||
/** | ||
* Return string representation of object | ||
* | ||
* @return string | ||
*/ | ||
public function toString() | ||
{ | ||
return self::SUCCESS_MESSAGE . ' message is present on UserEdit page.'; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters