Find this useful? Enter your email to receive occasional updates for securing PHP code.
Signing you up...
Thank you for signing up!
PHP Decode
<?php declare(strict_types=1); /** * ownCloud * * @author Jan Ackermann <jackermann@own..
Decoded Output download
<?php declare(strict_types=1);
/**
* ownCloud
*
* @author Jan Ackermann <[email protected]>
* @author Jannik Stehle <[email protected]>
* @copyright Copyright (c) 2021, ownCloud GmbH
*
* This code is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License,
* as published by the Free Software Foundation;
* either version 3 of the License, or any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>
*
*/
use Behat\Behat\Context\Context;
use Behat\MinkExtension\Context\RawMinkContext;
use Page\FilesPageElement\NewFileMenu;
use PHPUnit\Framework\Assert;
require_once 'bootstrap.php';
/**
* Context for new file menu
*/
class WebUINewFileMenuContext extends RawMinkContext implements Context {
private NewFileMenu $newFileMenu;
/**
* WebUINewFileMenuContext constructor.
*
* @param NewFileMenu $newFileMenu
*
*/
public function __construct(
NewFileMenu $newFileMenu
) {
$this->newFileMenu = $newFileMenu;
}
/**
* @When the user opens the newFileMenu using the webUI
*
* @return void
*/
public function theUserOpensTheNewFileMenuUsingTheWebUI():void {
$this->newFileMenu->openNewFileMenu();
}
/**
* @Then the newFileMenu should be displayed on the webUI
*
* @return void
*/
public function theNewFileMenuShouldBeDisplayedOnTheWebUI():void {
Assert::assertNotNull(
$this->newFileMenu->getNewFileMenu(),
'New file menu is expected to be visible but is not'
);
}
/**
* @Given the user clicks folder in the newFileMenu using the webUI
*
* @return void
*/
public function theUserClicksFolderInTheNewFileMenuUsingTheWebUI():void {
$this->newFileMenu->clickFolder();
}
/**
* @Then the newFileMenu filename form should be displayed on the webUI
*
* @return void
*/
public function theNewFileMenuFilenameFormShouldBeDisplayedOnTheWebUI():void {
Assert::assertNotNull(
$this->newFileMenu->getNewFileMenuFilenameForm(),
'New file menu filename form is expected to be visible but is not'
);
}
/**
* @Then the newFileMenu filename form should not be displayed on the webUI
*
* @return void
*/
public function theNewFileMenuFilenameFormShouldNotBeDisplayedOnTheWebUI():void {
Assert::assertNull(
$this->newFileMenu->getNewFileMenuFilenameForm(),
'New file menu filename form is expected to be not visible but is'
);
}
/**
* @Given the user clicks cancel in newFileMenu filename form using the webUI
*
* @return void
*/
public function theUserClicksCancelInTheNewFileMenuFilenameFormUsingTheWebUI():void {
$this->newFileMenu->clickCancelFilenameForm();
}
}
?>
Did this file decode correctly?
Original Code
<?php declare(strict_types=1);
/**
* ownCloud
*
* @author Jan Ackermann <[email protected]>
* @author Jannik Stehle <[email protected]>
* @copyright Copyright (c) 2021, ownCloud GmbH
*
* This code is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License,
* as published by the Free Software Foundation;
* either version 3 of the License, or any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>
*
*/
use Behat\Behat\Context\Context;
use Behat\MinkExtension\Context\RawMinkContext;
use Page\FilesPageElement\NewFileMenu;
use PHPUnit\Framework\Assert;
require_once 'bootstrap.php';
/**
* Context for new file menu
*/
class WebUINewFileMenuContext extends RawMinkContext implements Context {
private NewFileMenu $newFileMenu;
/**
* WebUINewFileMenuContext constructor.
*
* @param NewFileMenu $newFileMenu
*
*/
public function __construct(
NewFileMenu $newFileMenu
) {
$this->newFileMenu = $newFileMenu;
}
/**
* @When the user opens the newFileMenu using the webUI
*
* @return void
*/
public function theUserOpensTheNewFileMenuUsingTheWebUI():void {
$this->newFileMenu->openNewFileMenu();
}
/**
* @Then the newFileMenu should be displayed on the webUI
*
* @return void
*/
public function theNewFileMenuShouldBeDisplayedOnTheWebUI():void {
Assert::assertNotNull(
$this->newFileMenu->getNewFileMenu(),
'New file menu is expected to be visible but is not'
);
}
/**
* @Given the user clicks folder in the newFileMenu using the webUI
*
* @return void
*/
public function theUserClicksFolderInTheNewFileMenuUsingTheWebUI():void {
$this->newFileMenu->clickFolder();
}
/**
* @Then the newFileMenu filename form should be displayed on the webUI
*
* @return void
*/
public function theNewFileMenuFilenameFormShouldBeDisplayedOnTheWebUI():void {
Assert::assertNotNull(
$this->newFileMenu->getNewFileMenuFilenameForm(),
'New file menu filename form is expected to be visible but is not'
);
}
/**
* @Then the newFileMenu filename form should not be displayed on the webUI
*
* @return void
*/
public function theNewFileMenuFilenameFormShouldNotBeDisplayedOnTheWebUI():void {
Assert::assertNull(
$this->newFileMenu->getNewFileMenuFilenameForm(),
'New file menu filename form is expected to be not visible but is'
);
}
/**
* @Given the user clicks cancel in newFileMenu filename form using the webUI
*
* @return void
*/
public function theUserClicksCancelInTheNewFileMenuFilenameFormUsingTheWebUI():void {
$this->newFileMenu->clickCancelFilenameForm();
}
}
Function Calls
None |
Stats
MD5 | ebb79b1293e7674a98cd9c77a6b8f889 |
Eval Count | 0 |
Decode Time | 102 ms |