yii2-netdisk/tests/functional/TestGuy.php
2013-06-22 20:26:22 -04:00

249 lines
6.5 KiB
PHP

<?php
// This class was automatically generated by build task
// You can change it manually, but it will be overwritten on next build
// @codingStandardsIgnoreFile
use Codeception\Maybe;
use Codeception\Module\Filesystem;
use Codeception\Module\TestHelper;
/**
* Inherited methods
* @method void wantToTest($text)
* @method void wantTo($text)
* @method void amTesting($method)
* @method void amTestingMethod($method)
* @method void testMethod($signature)
* @method void expectTo($prediction)
* @method void expect($prediction)
* @method void amGoingTo($argumentation)
* @method void am($role)
* @method void lookForwardTo($role)
*/
class TestGuy extends \Codeception\AbstractGuy
{
/**
* Enters a directory In local filesystem.
* Project root directory is used by default
*
* @param $path
* @see Filesystem::amInPath()
* @return \Codeception\Maybe
* ! This method is generated. DO NOT EDIT. !
* ! Documentation taken from corresponding module !
*/
public function amInPath($path) {
$this->scenario->condition('amInPath', func_get_args());
if ($this->scenario->running()) {
$result = $this->scenario->runStep();
return new Maybe($result);
}
return new Maybe();
}
/**
* Opens a file and stores it's content.
*
* Usage:
*
* ``` php
* <?php
* $I->openFile('composer.json');
* $I->seeInThisFile('codeception/codeception');
* ?>
* ```
*
* @param $filename
* @see Filesystem::openFile()
* @return \Codeception\Maybe
* ! This method is generated. DO NOT EDIT. !
* ! Documentation taken from corresponding module !
*/
public function openFile($filename) {
$this->scenario->action('openFile', func_get_args());
if ($this->scenario->running()) {
$result = $this->scenario->runStep();
return new Maybe($result);
}
return new Maybe();
}
/**
* Deletes a file
*
* ``` php
* <?php
* $I->deleteFile('composer.lock');
* ?>
* ```
*
* @param $filename
* @see Filesystem::deleteFile()
* @return \Codeception\Maybe
* ! This method is generated. DO NOT EDIT. !
* ! Documentation taken from corresponding module !
*/
public function deleteFile($filename) {
$this->scenario->action('deleteFile', func_get_args());
if ($this->scenario->running()) {
$result = $this->scenario->runStep();
return new Maybe($result);
}
return new Maybe();
}
/**
* Deletes directory with all subdirectories
*
* ``` php
* <?php
* $I->deleteDir('vendor');
* ?>
* ```
*
* @param $dirname
* @see Filesystem::deleteDir()
* @return \Codeception\Maybe
* ! This method is generated. DO NOT EDIT. !
* ! Documentation taken from corresponding module !
*/
public function deleteDir($dirname) {
$this->scenario->action('deleteDir', func_get_args());
if ($this->scenario->running()) {
$result = $this->scenario->runStep();
return new Maybe($result);
}
return new Maybe();
}
/**
* Copies directory with all contents
*
* ``` php
* <?php
* $I->copyDir('vendor','old_vendor');
* ?>
* ```
*
* @param $src
* @param $dst
* @see Filesystem::copyDir()
* @return \Codeception\Maybe
* ! This method is generated. DO NOT EDIT. !
* ! Documentation taken from corresponding module !
*/
public function copyDir($src, $dst) {
$this->scenario->action('copyDir', func_get_args());
if ($this->scenario->running()) {
$result = $this->scenario->runStep();
return new Maybe($result);
}
return new Maybe();
}
/**
* Checks If opened file has `text` in it.
*
* Usage:
*
* ``` php
* <?php
* $I->openFile('composer.json');
* $I->seeInThisFile('codeception/codeception');
* ?>
* ```
*
* @param $text
* @see Filesystem::seeInThisFile()
* @return \Codeception\Maybe
* ! This method is generated. DO NOT EDIT. !
* ! Documentation taken from corresponding module !
*/
public function seeInThisFile($text) {
$this->scenario->assertion('seeInThisFile', func_get_args());
if ($this->scenario->running()) {
$result = $this->scenario->runStep();
return new Maybe($result);
}
return new Maybe();
}
/**
* Checks If opened file doesn't contain `text` in it
*
* ``` php
* <?php
* $I->openFile('composer.json');
* $I->seeInThisFile('codeception/codeception');
* ?>
* ```
*
* @param $text
* @see Filesystem::dontSeeInThisFile()
* @return \Codeception\Maybe
* ! This method is generated. DO NOT EDIT. !
* ! Documentation taken from corresponding module !
*/
public function dontSeeInThisFile($text) {
$this->scenario->action('dontSeeInThisFile', func_get_args());
if ($this->scenario->running()) {
$result = $this->scenario->runStep();
return new Maybe($result);
}
return new Maybe();
}
/**
* Deletes a file
* @see Filesystem::deleteThisFile()
* @return \Codeception\Maybe
* ! This method is generated. DO NOT EDIT. !
* ! Documentation taken from corresponding module !
*/
public function deleteThisFile() {
$this->scenario->action('deleteThisFile', func_get_args());
if ($this->scenario->running()) {
$result = $this->scenario->runStep();
return new Maybe($result);
}
return new Maybe();
}
/**
* Checks if file exists in path.
* Opens a file when it's exists
*
* ``` php
* <?php
* $I->seeFileFound('UserModel.php','app/models');
* ?>
* ```
*
* @param $filename
* @param string $path
* @see Filesystem::seeFileFound()
* @return \Codeception\Maybe
* ! This method is generated. DO NOT EDIT. !
* ! Documentation taken from corresponding module !
*/
public function seeFileFound($filename, $path = null) {
$this->scenario->assertion('seeFileFound', func_get_args());
if ($this->scenario->running()) {
$result = $this->scenario->runStep();
return new Maybe($result);
}
return new Maybe();
}
}