diff options
Diffstat (limited to 'tests/acceptance')
34 files changed, 8 insertions, 61 deletions
diff --git a/tests/acceptance/features/bootstrap/AppNavigationContext.php b/tests/acceptance/features/bootstrap/AppNavigationContext.php index 0fd9e92e9e4..427af0e40c9 100644 --- a/tests/acceptance/features/bootstrap/AppNavigationContext.php +++ b/tests/acceptance/features/bootstrap/AppNavigationContext.php @@ -25,7 +25,6 @@ use Behat\Behat\Context\Context; class AppNavigationContext implements Context, ActorAwareInterface { - use ActorAware; /** @@ -141,5 +140,4 @@ class AppNavigationContext implements Context, ActorAwareInterface { PHPUnit_Framework_Assert::fail("The counter for section $section is still shown after $timeout seconds"); } } - } diff --git a/tests/acceptance/features/bootstrap/AppSettingsContext.php b/tests/acceptance/features/bootstrap/AppSettingsContext.php index a75cce29936..b2b6744a36b 100644 --- a/tests/acceptance/features/bootstrap/AppSettingsContext.php +++ b/tests/acceptance/features/bootstrap/AppSettingsContext.php @@ -25,7 +25,6 @@ use Behat\Behat\Context\Context; class AppSettingsContext implements Context, ActorAwareInterface { - use ActorAware; /** @@ -98,5 +97,4 @@ class AppSettingsContext implements Context, ActorAwareInterface { public function iSeeThatTheSettingsAreOpened() { WaitFor::elementToBeEventuallyShown($this->actor, self::appSettingsContent()); } - } diff --git a/tests/acceptance/features/bootstrap/AppsManagementContext.php b/tests/acceptance/features/bootstrap/AppsManagementContext.php index 2fa089e3cba..1e36ac72ef6 100644 --- a/tests/acceptance/features/bootstrap/AppsManagementContext.php +++ b/tests/acceptance/features/bootstrap/AppsManagementContext.php @@ -26,7 +26,6 @@ use Behat\Behat\Context\Context; class AppsManagementContext implements Context, ActorAwareInterface { - use ActorAware; /** @@ -227,6 +226,4 @@ class AppsManagementContext implements Context, ActorAwareInterface { PHPUnit_Framework_Assert::fail("The sidebar was not shown yet after $timeout seconds"); } } - - } diff --git a/tests/acceptance/features/bootstrap/ContactsMenuContext.php b/tests/acceptance/features/bootstrap/ContactsMenuContext.php index 4cb2e5885d5..860e84fa950 100644 --- a/tests/acceptance/features/bootstrap/ContactsMenuContext.php +++ b/tests/acceptance/features/bootstrap/ContactsMenuContext.php @@ -24,7 +24,6 @@ use Behat\Behat\Context\Context; class ContactsMenuContext implements Context, ActorAwareInterface { - use ActorAware; /** @@ -143,5 +142,4 @@ class ContactsMenuContext implements Context, ActorAwareInterface { PHPUnit_Framework_Assert::fail("The $contactName contact in Contacts menu is still shown after $timeout seconds"); } } - } diff --git a/tests/acceptance/features/bootstrap/DialogContext.php b/tests/acceptance/features/bootstrap/DialogContext.php index 0558123ad9d..f9d2d6244e9 100644 --- a/tests/acceptance/features/bootstrap/DialogContext.php +++ b/tests/acceptance/features/bootstrap/DialogContext.php @@ -24,7 +24,6 @@ use Behat\Behat\Context\Context; class DialogContext implements Context, ActorAwareInterface { - use ActorAware; /** @@ -64,5 +63,4 @@ class DialogContext implements Context, ActorAwareInterface { public function iSeeThatTheConfirmationDialogIsNotShown() { WaitFor::elementToBeEventuallyNotShown($this->actor, self::theDialog()); } - } diff --git a/tests/acceptance/features/bootstrap/FeatureContext.php b/tests/acceptance/features/bootstrap/FeatureContext.php index a125ea01ccc..72798ea98f7 100644 --- a/tests/acceptance/features/bootstrap/FeatureContext.php +++ b/tests/acceptance/features/bootstrap/FeatureContext.php @@ -24,7 +24,6 @@ use Behat\Behat\Context\Context; class FeatureContext implements Context, ActorAwareInterface { - use ActorAware; /** @@ -33,5 +32,4 @@ class FeatureContext implements Context, ActorAwareInterface { public function iVisitTheHomePage() { $this->actor->getSession()->visit($this->actor->locatePath("/")); } - } diff --git a/tests/acceptance/features/bootstrap/FileListAncestorSetter.php b/tests/acceptance/features/bootstrap/FileListAncestorSetter.php index d914edf234f..af8534f012c 100644 --- a/tests/acceptance/features/bootstrap/FileListAncestorSetter.php +++ b/tests/acceptance/features/bootstrap/FileListAncestorSetter.php @@ -62,5 +62,4 @@ trait FileListAncestorSetter { private function setFileListAncestorForActor($fileListAncestor, Actor $actor) { $this->fileListContext->setFileListAncestorForActor($fileListAncestor, $actor); } - } diff --git a/tests/acceptance/features/bootstrap/FileListContext.php b/tests/acceptance/features/bootstrap/FileListContext.php index 745f522d874..72c5c012dd1 100644 --- a/tests/acceptance/features/bootstrap/FileListContext.php +++ b/tests/acceptance/features/bootstrap/FileListContext.php @@ -552,5 +552,4 @@ class FileListContext implements Context, ActorAwareInterface { public function iSeeThatHasUnreadComments($fileName) { PHPUnit_Framework_Assert::assertTrue($this->actor->find(self::commentActionForFile($this->fileListAncestor, $fileName), 10)->isVisible()); } - } diff --git a/tests/acceptance/features/bootstrap/FilePickerContext.php b/tests/acceptance/features/bootstrap/FilePickerContext.php index d7659dbac8e..b9d82090eaa 100644 --- a/tests/acceptance/features/bootstrap/FilePickerContext.php +++ b/tests/acceptance/features/bootstrap/FilePickerContext.php @@ -24,7 +24,6 @@ use Behat\Behat\Context\Context; class FilePickerContext implements Context, ActorAwareInterface { - use ActorAware; /** @@ -123,5 +122,4 @@ class FilePickerContext implements Context, ActorAwareInterface { public function iChooseTheLastSelectedFileInTheFilePicker() { $this->actor->find(self::chooseButton(), 10)->click(); } - } diff --git a/tests/acceptance/features/bootstrap/FilesAppContext.php b/tests/acceptance/features/bootstrap/FilesAppContext.php index 6a816d7f368..a5dcfb700ba 100644 --- a/tests/acceptance/features/bootstrap/FilesAppContext.php +++ b/tests/acceptance/features/bootstrap/FilesAppContext.php @@ -24,7 +24,6 @@ use Behat\Behat\Context\Context; class FilesAppContext implements Context, ActorAwareInterface { - use ActorAware; use FileListAncestorSetter; diff --git a/tests/acceptance/features/bootstrap/FilesAppSharingContext.php b/tests/acceptance/features/bootstrap/FilesAppSharingContext.php index 040c5c4dd75..6b30d49d71e 100644 --- a/tests/acceptance/features/bootstrap/FilesAppSharingContext.php +++ b/tests/acceptance/features/bootstrap/FilesAppSharingContext.php @@ -24,7 +24,6 @@ use Behat\Behat\Context\Context; class FilesAppSharingContext implements Context, ActorAwareInterface { - use ActorAware; /** diff --git a/tests/acceptance/features/bootstrap/LoginPageContext.php b/tests/acceptance/features/bootstrap/LoginPageContext.php index ceb90263e4e..bf44d31fb03 100644 --- a/tests/acceptance/features/bootstrap/LoginPageContext.php +++ b/tests/acceptance/features/bootstrap/LoginPageContext.php @@ -25,7 +25,6 @@ use Behat\Behat\Context\Context; use Behat\Behat\Hook\Scope\BeforeScenarioScope; class LoginPageContext implements Context, ActorAwareInterface { - use ActorAware; /** @@ -158,5 +157,4 @@ class LoginPageContext implements Context, ActorAwareInterface { $this->iSeeThatTheCurrentPageIsTheLoginPage(); $this->iSeeThatAWrongPasswordMessageIsShown(); } - } diff --git a/tests/acceptance/features/bootstrap/NotificationsContext.php b/tests/acceptance/features/bootstrap/NotificationsContext.php index 13717b0ba03..15ad6ee90c8 100644 --- a/tests/acceptance/features/bootstrap/NotificationsContext.php +++ b/tests/acceptance/features/bootstrap/NotificationsContext.php @@ -24,7 +24,6 @@ use Behat\Behat\Context\Context; class NotificationsContext implements Context, ActorAwareInterface { - use ActorAware; /** @@ -94,5 +93,4 @@ class NotificationsContext implements Context, ActorAwareInterface { // Hide the notifications again $this->actor->find(self::notificationsButton(), 10)->click(); } - } diff --git a/tests/acceptance/features/bootstrap/PublicShareContext.php b/tests/acceptance/features/bootstrap/PublicShareContext.php index 891c231b164..2213cf877f9 100644 --- a/tests/acceptance/features/bootstrap/PublicShareContext.php +++ b/tests/acceptance/features/bootstrap/PublicShareContext.php @@ -24,7 +24,6 @@ use Behat\Behat\Context\Context; class PublicShareContext implements Context, ActorAwareInterface { - use ActorAware; use FileListAncestorSetter; @@ -250,5 +249,4 @@ class PublicShareContext implements Context, ActorAwareInterface { } catch (NoSuchElementException $exception) { } } - } diff --git a/tests/acceptance/features/bootstrap/SearchContext.php b/tests/acceptance/features/bootstrap/SearchContext.php index d2d6b708067..bd4ba2beaef 100644 --- a/tests/acceptance/features/bootstrap/SearchContext.php +++ b/tests/acceptance/features/bootstrap/SearchContext.php @@ -24,7 +24,6 @@ use Behat\Behat\Context\Context; class SearchContext implements Context, ActorAwareInterface { - use ActorAware; /** @@ -111,5 +110,4 @@ class SearchContext implements Context, ActorAwareInterface { PHPUnit_Framework_Assert::assertEquals( $path, $this->actor->find(self::searchResultPath($number), 10)->getText()); } - } diff --git a/tests/acceptance/features/bootstrap/SettingsContext.php b/tests/acceptance/features/bootstrap/SettingsContext.php index ccc010e38e9..60499c96bd1 100644 --- a/tests/acceptance/features/bootstrap/SettingsContext.php +++ b/tests/acceptance/features/bootstrap/SettingsContext.php @@ -24,7 +24,6 @@ use Behat\Behat\Context\Context; class SettingsContext implements Context, ActorAwareInterface { - use ActorAware; /** @@ -236,5 +235,4 @@ class SettingsContext implements Context, ActorAwareInterface { PHPUnit_Framework_Assert::fail("The dropdown in system tags section in Administration Settings does not contain the tag $tag after $numberOfTries tries"); } - } diff --git a/tests/acceptance/features/bootstrap/SettingsMenuContext.php b/tests/acceptance/features/bootstrap/SettingsMenuContext.php index a740e98756b..485f945f04c 100644 --- a/tests/acceptance/features/bootstrap/SettingsMenuContext.php +++ b/tests/acceptance/features/bootstrap/SettingsMenuContext.php @@ -25,7 +25,6 @@ use Behat\Behat\Context\Context; class SettingsMenuContext implements Context, ActorAwareInterface { - use ActorAware; /** @@ -217,5 +216,4 @@ class SettingsMenuContext implements Context, ActorAwareInterface { } catch (NoSuchElementException $exception) { } } - } diff --git a/tests/acceptance/features/bootstrap/ThemingAppContext.php b/tests/acceptance/features/bootstrap/ThemingAppContext.php index e52c1c86b03..de25bafd6c3 100644 --- a/tests/acceptance/features/bootstrap/ThemingAppContext.php +++ b/tests/acceptance/features/bootstrap/ThemingAppContext.php @@ -24,7 +24,6 @@ use Behat\Behat\Context\Context; class ThemingAppContext implements Context, ActorAwareInterface { - use ActorAware; /** @@ -110,15 +109,15 @@ class ThemingAppContext implements Context, ActorAwareInterface { private function getRGBArray($color) { if (preg_match("/rgb\(\s*(\d+),\s*(\d+),\s*(\d+)\)/", $color, $matches)) { - // Already an RGB (R, G, B) color - // Convert from "rgb(R, G, B)" string to RGB array - $tmpColor = array_splice($matches, 1); - } else if ($color[0] === '#') { - $color = substr($color, 1); - // HEX Color, convert to RGB array. - $tmpColor = sscanf($color, "%02X%02X%02X"); + // Already an RGB (R, G, B) color + // Convert from "rgb(R, G, B)" string to RGB array + $tmpColor = array_splice($matches, 1); + } elseif ($color[0] === '#') { + $color = substr($color, 1); + // HEX Color, convert to RGB array. + $tmpColor = sscanf($color, "%02X%02X%02X"); } else { - PHPUnit_Framework_Assert::fail("The acceptance test does not know how to handle the color string : '$color'. " + PHPUnit_Framework_Assert::fail("The acceptance test does not know how to handle the color string : '$color'. " . "Please provide # before HEX colors in your features."); } return $tmpColor; @@ -161,5 +160,4 @@ class ThemingAppContext implements Context, ActorAwareInterface { PHPUnit_Framework_Assert::fail("The 'Saved' status messages in Theming app has not been shown after $timeout seconds"); } } - } diff --git a/tests/acceptance/features/bootstrap/ToastContext.php b/tests/acceptance/features/bootstrap/ToastContext.php index 28c81f8c50d..62b15c74c71 100644 --- a/tests/acceptance/features/bootstrap/ToastContext.php +++ b/tests/acceptance/features/bootstrap/ToastContext.php @@ -24,7 +24,6 @@ use Behat\Behat\Context\Context; class ToastContext implements Context, ActorAwareInterface { - use ActorAware; /** @@ -51,5 +50,4 @@ class ToastContext implements Context, ActorAwareInterface { PHPUnit_Framework_Assert::assertTrue($this->actor->find( self::toastMessage($message), 10)->isVisible()); } - } diff --git a/tests/acceptance/features/bootstrap/UsersSettingsContext.php b/tests/acceptance/features/bootstrap/UsersSettingsContext.php index d42b49cbf2d..020da466128 100644 --- a/tests/acceptance/features/bootstrap/UsersSettingsContext.php +++ b/tests/acceptance/features/bootstrap/UsersSettingsContext.php @@ -26,7 +26,6 @@ use Behat\Behat\Context\Context; class UsersSettingsContext implements Context, ActorAwareInterface { - use ActorAware; /** diff --git a/tests/acceptance/features/bootstrap/WaitFor.php b/tests/acceptance/features/bootstrap/WaitFor.php index 0b79d023ee5..b07586c4662 100644 --- a/tests/acceptance/features/bootstrap/WaitFor.php +++ b/tests/acceptance/features/bootstrap/WaitFor.php @@ -74,5 +74,4 @@ class WaitFor { return Utils::waitFor($elementNotShownCallback, $timeout, $timeoutStep); } - } diff --git a/tests/acceptance/features/core/Actor.php b/tests/acceptance/features/core/Actor.php index f47373593e9..ea33e7df21e 100644 --- a/tests/acceptance/features/core/Actor.php +++ b/tests/acceptance/features/core/Actor.php @@ -212,5 +212,4 @@ class Actor { public function &getSharedNotebook() { return $this->sharedNotebook; } - } diff --git a/tests/acceptance/features/core/ActorAware.php b/tests/acceptance/features/core/ActorAware.php index cc98ad7770d..5a1a7542355 100644 --- a/tests/acceptance/features/core/ActorAware.php +++ b/tests/acceptance/features/core/ActorAware.php @@ -34,5 +34,4 @@ trait ActorAware { public function setCurrentActor(Actor $actor) { $this->actor = $actor; } - } diff --git a/tests/acceptance/features/core/ActorAwareInterface.php b/tests/acceptance/features/core/ActorAwareInterface.php index 9363bc3e607..37261773cbb 100644 --- a/tests/acceptance/features/core/ActorAwareInterface.php +++ b/tests/acceptance/features/core/ActorAwareInterface.php @@ -27,5 +27,4 @@ interface ActorAwareInterface { * @param Actor $actor */ public function setCurrentActor(Actor $actor); - } diff --git a/tests/acceptance/features/core/ActorContext.php b/tests/acceptance/features/core/ActorContext.php index 9ef34cae29f..932af5ff277 100644 --- a/tests/acceptance/features/core/ActorContext.php +++ b/tests/acceptance/features/core/ActorContext.php @@ -184,5 +184,4 @@ class ActorContext extends RawMinkContext { $actor->getSession()->stop(); } } - } diff --git a/tests/acceptance/features/core/ElementFinder.php b/tests/acceptance/features/core/ElementFinder.php index 5570637aa96..9981321c90d 100644 --- a/tests/acceptance/features/core/ElementFinder.php +++ b/tests/acceptance/features/core/ElementFinder.php @@ -201,5 +201,4 @@ class ElementFinder { public function find() { return self::findInternal($this->session, $this->elementLocator, $this->timeout, $this->timeoutStep); } - } diff --git a/tests/acceptance/features/core/ElementWrapper.php b/tests/acceptance/features/core/ElementWrapper.php index 97b1b4bfbcd..d5f7ef495c1 100644 --- a/tests/acceptance/features/core/ElementWrapper.php +++ b/tests/acceptance/features/core/ElementWrapper.php @@ -333,5 +333,4 @@ class ElementWrapper { return Utils::waitFor($isVisibleCallback, $timeout, $timeoutStep); } - } diff --git a/tests/acceptance/features/core/Locator.php b/tests/acceptance/features/core/Locator.php index e3577f296f4..dd971147f86 100644 --- a/tests/acceptance/features/core/Locator.php +++ b/tests/acceptance/features/core/Locator.php @@ -99,7 +99,6 @@ class Locator { public function getAncestor() { return $this->ancestor; } - } class LocatorBuilder { @@ -240,7 +239,6 @@ class LocatorBuilder { public function table($value) { return $this->customSelector("named_exact", ["table", $value]); } - } class LocatorBuilderSecondStep { @@ -279,7 +277,6 @@ class LocatorBuilderSecondStep { public function describedAs($description) { return new Locator($description, $this->selector, $this->locator); } - } class LocatorBuilderThirdStep { @@ -317,5 +314,4 @@ class LocatorBuilderThirdStep { public function describedAs($description) { return new Locator($description, $this->selector, $this->locator, $this->ancestor); } - } diff --git a/tests/acceptance/features/core/NextcloudTestServerContext.php b/tests/acceptance/features/core/NextcloudTestServerContext.php index 8540a71a4f4..682811248e1 100644 --- a/tests/acceptance/features/core/NextcloudTestServerContext.php +++ b/tests/acceptance/features/core/NextcloudTestServerContext.php @@ -124,5 +124,4 @@ class NextcloudTestServerContext implements Context { } } } - } diff --git a/tests/acceptance/features/core/NextcloudTestServerHelper.php b/tests/acceptance/features/core/NextcloudTestServerHelper.php index 198d78e3fcb..cd50616e34c 100644 --- a/tests/acceptance/features/core/NextcloudTestServerHelper.php +++ b/tests/acceptance/features/core/NextcloudTestServerHelper.php @@ -69,5 +69,4 @@ interface NextcloudTestServerHelper { * @throws \Exception if the base URL can not be determined. */ public function getBaseUrl(); - } diff --git a/tests/acceptance/features/core/NextcloudTestServerLocalApacheHelper.php b/tests/acceptance/features/core/NextcloudTestServerLocalApacheHelper.php index a2dd6664c6f..36cffc325dc 100644 --- a/tests/acceptance/features/core/NextcloudTestServerLocalApacheHelper.php +++ b/tests/acceptance/features/core/NextcloudTestServerLocalApacheHelper.php @@ -126,5 +126,4 @@ class NextcloudTestServerLocalApacheHelper implements NextcloudTestServerHelper private function stopApacheServer() { $this->execOrException("service apache2 stop"); } - } diff --git a/tests/acceptance/features/core/NextcloudTestServerLocalBuiltInHelper.php b/tests/acceptance/features/core/NextcloudTestServerLocalBuiltInHelper.php index 1e74f5c66d1..ce81881c9c4 100644 --- a/tests/acceptance/features/core/NextcloudTestServerLocalBuiltInHelper.php +++ b/tests/acceptance/features/core/NextcloudTestServerLocalBuiltInHelper.php @@ -140,5 +140,4 @@ class NextcloudTestServerLocalBuiltInHelper implements NextcloudTestServerHelper $this->phpServerPid = ""; } - } diff --git a/tests/acceptance/features/core/NoSuchElementException.php b/tests/acceptance/features/core/NoSuchElementException.php index 5f8270d2a49..dca884556ad 100644 --- a/tests/acceptance/features/core/NoSuchElementException.php +++ b/tests/acceptance/features/core/NoSuchElementException.php @@ -33,5 +33,4 @@ class NoSuchElementException extends \Exception { public function __construct($message, \Exception $previous = null) { parent::__construct($message, 0, $previous); } - } diff --git a/tests/acceptance/features/core/Utils.php b/tests/acceptance/features/core/Utils.php index f81542eb079..1650df4f824 100644 --- a/tests/acceptance/features/core/Utils.php +++ b/tests/acceptance/features/core/Utils.php @@ -86,5 +86,4 @@ class Utils { }; return self::waitFor($isServerUpCallback, $timeout, $timeoutStep); } - } |