diff options
author | Joas Schilling <coding@schilljs.com> | 2022-09-01 09:19:51 +0200 |
---|---|---|
committer | Joas Schilling <coding@schilljs.com> | 2022-09-01 10:53:38 +0200 |
commit | a22a546401cfe5546afea968ce74028a2f5eb878 (patch) | |
tree | 645c3ae8405ef429e24531a06119bf7050eba4ea /tests | |
parent | 1cdd96a113eb4912631463c8d273d47f58f0c7a6 (diff) |
Adjust coding style
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'tests')
48 files changed, 81 insertions, 110 deletions
diff --git a/tests/acceptance/features/bootstrap/ChatAncestorSetter.php b/tests/acceptance/features/bootstrap/ChatAncestorSetter.php index 2ded22ba9..5b613dc93 100644 --- a/tests/acceptance/features/bootstrap/ChatAncestorSetter.php +++ b/tests/acceptance/features/bootstrap/ChatAncestorSetter.php @@ -36,7 +36,6 @@ use Behat\Behat\Hook\Scope\BeforeScenarioScope; * when needed. */ trait ChatAncestorSetter { - /** * @var ChatContext */ diff --git a/tests/acceptance/features/bootstrap/ChatContext.php b/tests/acceptance/features/bootstrap/ChatContext.php index 7af0256d8..d0446e1a0 100644 --- a/tests/acceptance/features/bootstrap/ChatContext.php +++ b/tests/acceptance/features/bootstrap/ChatContext.php @@ -24,7 +24,6 @@ use Behat\Behat\Context\Context; class ChatContext implements Context, ActorAwareInterface { - /** * @var Actor */ @@ -329,9 +328,9 @@ class ChatContext implements Context, ActorAwareInterface { // Instead of waiting for the input to be enabled before sending a new // message it is easier to wait for the working icon to not be shown. if (!WaitFor::elementToBeEventuallyNotShown( - $this->actor, - self::newChatMessageWorkingIcon($this->chatAncestor), - $timeout = 10 * $this->actor->getFindTimeoutMultiplier())) { + $this->actor, + self::newChatMessageWorkingIcon($this->chatAncestor), + $timeout = 10 * $this->actor->getFindTimeoutMultiplier())) { PHPUnit_Framework_Assert::fail("The working icon for the new message was still being shown after $timeout seconds"); } @@ -359,9 +358,9 @@ class ChatContext implements Context, ActorAwareInterface { // Instead of waiting for the input to be enabled before sending a new // message it is easier to wait for the working icon to not be shown. if (!WaitFor::elementToBeEventuallyNotShown( - $this->actor, - self::newChatMessageWorkingIcon($this->chatAncestor), - $timeout = 10 * $this->actor->getFindTimeoutMultiplier())) { + $this->actor, + self::newChatMessageWorkingIcon($this->chatAncestor), + $timeout = 10 * $this->actor->getFindTimeoutMultiplier())) { PHPUnit_Framework_Assert::fail("The working icon for the new message was still being shown after $timeout seconds"); } @@ -394,17 +393,17 @@ class ChatContext implements Context, ActorAwareInterface { */ public function iSeeThatTheMessageWasSentByWithTheText($number, $author, $message) { if (!WaitFor::elementToBeEventuallyShown( - $this->actor, - self::authorOfChatMessage($this->chatAncestor, $number), - $timeout = 10 * $this->actor->getFindTimeoutMultiplier())) { + $this->actor, + self::authorOfChatMessage($this->chatAncestor, $number), + $timeout = 10 * $this->actor->getFindTimeoutMultiplier())) { PHPUnit_Framework_Assert::fail("The author of the message $number was not shown yet after $timeout seconds"); } PHPUnit_Framework_Assert::assertEquals($author, $this->actor->find(self::authorOfChatMessage($this->chatAncestor, $number))->getText()); if (!WaitFor::elementToBeEventuallyShown( - $this->actor, - self::textOfChatMessage($this->chatAncestor, $number), - $timeout = 10 * $this->actor->getFindTimeoutMultiplier())) { + $this->actor, + self::textOfChatMessage($this->chatAncestor, $number), + $timeout = 10 * $this->actor->getFindTimeoutMultiplier())) { PHPUnit_Framework_Assert::fail("The text of the message $number was not shown yet after $timeout seconds"); } PHPUnit_Framework_Assert::assertEquals($message, $this->actor->find(self::textOfChatMessage($this->chatAncestor, $number))->getText()); @@ -415,9 +414,9 @@ class ChatContext implements Context, ActorAwareInterface { */ public function iSeeThatTheMessageWasSentWithTheTextAndGroupedWithThePreviousOne($number, $message) { if (!WaitFor::elementToBeEventuallyShown( - $this->actor, - self::textOfGroupedChatMessage($this->chatAncestor, $number), - $timeout = 10 * $this->actor->getFindTimeoutMultiplier())) { + $this->actor, + self::textOfGroupedChatMessage($this->chatAncestor, $number), + $timeout = 10 * $this->actor->getFindTimeoutMultiplier())) { PHPUnit_Framework_Assert::fail("The text of the message $number was not shown yet after $timeout seconds"); } PHPUnit_Framework_Assert::assertEquals($message, $this->actor->find(self::textOfGroupedChatMessage($this->chatAncestor, $number))->getText()); diff --git a/tests/acceptance/features/bootstrap/ConversationInfoContext.php b/tests/acceptance/features/bootstrap/ConversationInfoContext.php index 23381244d..5621ee3ec 100644 --- a/tests/acceptance/features/bootstrap/ConversationInfoContext.php +++ b/tests/acceptance/features/bootstrap/ConversationInfoContext.php @@ -251,9 +251,9 @@ class ConversationInfoContext implements Context, ActorAwareInterface { // menu. Therefore, if the menu is visible, wait a little just in case // it is in the process of being hidden due to a previous action. if (!WaitFor::elementToBeEventuallyNotShown( - $this->actor, - self::roomModerationMenu(), - $timeout = 5 * $this->actor->getFindTimeoutMultiplier())) { + $this->actor, + self::roomModerationMenu(), + $timeout = 5 * $this->actor->getFindTimeoutMultiplier())) { PHPUnit_Framework_Assert::fail("The room moderation menu is still shown after $timeout seconds"); } diff --git a/tests/acceptance/features/bootstrap/ConversationListContext.php b/tests/acceptance/features/bootstrap/ConversationListContext.php index 739ed42a6..1a32a1b98 100644 --- a/tests/acceptance/features/bootstrap/ConversationListContext.php +++ b/tests/acceptance/features/bootstrap/ConversationListContext.php @@ -227,9 +227,9 @@ class ConversationListContext implements Context, ActorAwareInterface { */ public function iSeeThatTheConversationIsShownInTheList($conversation) { if (!WaitFor::elementToBeEventuallyShown( - $this->actor, - self::conversationListItemFor($conversation), - $timeout = 10 * $this->actor->getFindTimeoutMultiplier())) { + $this->actor, + self::conversationListItemFor($conversation), + $timeout = 10 * $this->actor->getFindTimeoutMultiplier())) { PHPUnit_Framework_Assert::fail("The $conversation conversation is not shown yet in the list after $timeout seconds"); } } @@ -239,9 +239,9 @@ class ConversationListContext implements Context, ActorAwareInterface { */ public function iSeeThatTheConversationIsNotShownInTheList($conversation) { if (!WaitFor::elementToBeEventuallyNotShown( - $this->actor, - self::conversationListItemFor($conversation), - $timeout = 10 * $this->actor->getFindTimeoutMultiplier())) { + $this->actor, + self::conversationListItemFor($conversation), + $timeout = 10 * $this->actor->getFindTimeoutMultiplier())) { PHPUnit_Framework_Assert::fail("The $conversation conversation is still shown in the list after $timeout seconds"); } } @@ -256,9 +256,9 @@ class ConversationListContext implements Context, ActorAwareInterface { // waited for it to be visible instead of relying on the implicit wait // made to find the element. if (!WaitFor::elementToBeEventuallyShown( - $this->actor, - self::activeConversationListItemFor($conversation), - $timeout = 10 * $this->actor->getFindTimeoutMultiplier())) { + $this->actor, + self::activeConversationListItemFor($conversation), + $timeout = 10 * $this->actor->getFindTimeoutMultiplier())) { PHPUnit_Framework_Assert::fail("The $conversation conversation is not active yet after $timeout seconds"); } } @@ -268,9 +268,9 @@ class ConversationListContext implements Context, ActorAwareInterface { */ public function iSeeThatTheConversationIsNotActive($conversation) { if (!WaitFor::elementToBeEventuallyNotShown( - $this->actor, - self::activeConversationListItemFor($conversation), - $timeout = 10 * $this->actor->getFindTimeoutMultiplier())) { + $this->actor, + self::activeConversationListItemFor($conversation), + $timeout = 10 * $this->actor->getFindTimeoutMultiplier())) { PHPUnit_Framework_Assert::fail("The $conversation conversation is still active after $timeout seconds"); } } |