/
var
/
www
/
vhosts
/
nabawater
/
vendor
/
codeception
/
base
/
tests
/
cli
/
/var/www/vhosts/nabawater/vendor/codeception/base/tests/cli
mkdir
upload
Name
Size
Mode
Actions
_steps/
-
0775
rm
AutoRebuildCept.php
504
0664
edit
dl
rm
BootstrapCest.php
3081
0664
edit
dl
rm
BuildCept.php
461
0664
edit
dl
rm
CodeceptionYmlInTestsDirCest.php
413
0664
edit
dl
rm
ConfigBundledSuitesCest.php
1132
0664
edit
dl
rm
ConfigExtendsCest.php
371
0664
edit
dl
rm
ConfigNoActorCest.php
1239
0664
edit
dl
rm
ConfigParamsCest.php
1384
0664
edit
dl
rm
ConfigValidateCest.php
1218
0664
edit
dl
rm
ConfigWithPresetsCest.php
241
0664
edit
dl
rm
DataProviderFailuresAndExceptionsCest.php
8271
0664
edit
dl
rm
DryRunCest.php
834
0664
edit
dl
rm
ExceptionInBeforeDoesNotMakeFatalErrorCept.php
679
0664
edit
dl
rm
ExtensionsCest.php
4151
0664
edit
dl
rm
GenerateCeptCept.php
762
0664
edit
dl
rm
GenerateCestCept.php
220
0664
edit
dl
rm
GenerateFeatureCept.php
478
0664
edit
dl
rm
GenerateGroupCept.php
392
0664
edit
dl
rm
GenerateHelperCept.php
273
0664
edit
dl
rm
GeneratePageObjectCest.php
1431
0664
edit
dl
rm
GenerateScenariosCept.php
323
0664
edit
dl
rm
GenerateStepObjectCept.php
299
0664
edit
dl
rm
GenerateSuiteCest.php
1639
0664
edit
dl
rm
GenerateTestCept.php
363
0664
edit
dl
rm
GherkinCest.php
3078
0664
edit
dl
rm
GlobalCommandOptionCest.php
2231
0664
edit
dl
rm
GroupEventsCept.php
410
0664
edit
dl
rm
GroupExtensionCept.php
544
0664
edit
dl
rm
IncludedCest.php
5354
0664
edit
dl
rm
MixedIncludeCest.php
648
0664
edit
dl
rm
OrderCest.php
4130
0664
edit
dl
rm
RegisterCommandCest.php
1145
0664
edit
dl
rm
RunCest.php
21485
0755
edit
dl
rm
RunEnvironmentCest.php
5284
0664
edit
dl
rm
RunIncompleteCept.php
299
0664
edit
dl
rm
RunSingleTestWithIncludeCest.php
418
0664
edit
dl
rm
RunSkippedCept.php
325
0664
edit
dl
rm
SecondTestIsExecutedWhenTheFirstTestFailsCest.php
1159
0664
edit
dl
rm
SnapshotCest.php
3208
0664
edit
dl
rm
UnitCept.php
941
0664
edit
dl
rm
WildcardIncludeCest.php
927
0664
edit
dl
rm
_bootstrap.php
96
0664
edit
dl
rm
Edit:
/var/www/vhosts/nabawater/vendor/codeception/base/tests/cli/RunEnvironmentCest.php
(5284B)
<?php class RunEnvironmentCest { public function testDevEnvironment(CliGuy $I) { $I->wantTo('execute test in --dev environment'); $I->amInPath('tests/data/sandbox'); $I->executeCommand('run dummy --env=dev'); $I->seeInShellOutput("OK ("); } public function testProdEnvironment(CliGuy $I) { $I->wantTo('execute test in non existent --prod environment'); $I->amInPath('tests/data/sandbox'); $I->executeCommand('run dummy --env=prod'); $I->dontSeeInShellOutput("OK ("); $I->seeInShellOutput("No tests executed"); } public function testEnvironmentParams(CliGuy $I) { $I->wantTo('execute check that env params applied'); $I->amInPath('tests/data/sandbox'); $I->executeCommand('run powers PowerIsRisingCept.php --env=dev -vv --steps'); $I->seeInShellOutput('I got the power'); $I->seeInShellOutput("PASSED"); $I->seeInShellOutput("OK ("); } public function testWithoutEnvironmentParams(CliGuy $I) { $I->wantTo('execute check that env params applied'); $I->amInPath('tests/data/sandbox'); $I->executeCommand('run powers PowerIsRisingCept.php -vv --no-exit'); $I->seeInShellOutput("I have no power"); $I->seeInShellOutput("FAIL"); } public function runTestForSpecificEnvironment(CliGuy $I) { $I->amInPath('tests/data/sandbox'); $I->executeCommand('run powers MageGuildCest.php --env whisky'); $I->seeInShellOutput('MageGuildCest: Red label'); $I->seeInShellOutput('MageGuildCest: Black label'); $I->seeInShellOutput('MageGuildCest: Power of the universe'); $I->seeInShellOutput('OK (3 tests, 3 assertions)'); } public function runTestForNotIncludedEnvironment(CliGuy $I) { $I->amInPath('tests/data/sandbox'); $I->executeCommand('run powers MageGuildCest.php --env dev'); $I->seeInShellOutput('MageGuildCest: Power of the universe'); $I->seeInShellOutput('OK (1 test, 1 assertion)'); } public function testEnvFileLoading(CliGuy $I) { $I->wantTo('test that env configuration files are loaded correctly'); $I->amInPath('tests/data/sandbox'); $I->executeCommand('run messages MessageCest.php:allMessages -vv --env env2'); $I->seeInShellOutput('message1: MESSAGE1 FROM ENV2-DIST.'); $I->seeInShellOutput('message2: MESSAGE2 FROM ENV2.'); $I->seeInShellOutput('message3: MESSAGE3 FROM SUITE.'); $I->seeInShellOutput('message4: DEFAULT MESSAGE4.'); } public function testEnvMerging(CliGuy $I) { $I->wantTo('test that given environments are merged properly'); $I->amInPath('tests/data/sandbox'); $I->executeCommand('run messages MessageCest.php:allMessages -vv --env env1,env2'); $I->seeInShellOutput('message1: MESSAGE1 FROM ENV2-DIST.'); $I->seeInShellOutput('message4: MESSAGE4 FROM SUITE-ENV1.'); $I->executeCommand('run messages MessageCest.php:allMessages -vv --env env2,env1'); $I->seeInShellOutput('message1: MESSAGE1 FROM SUITE-ENV1.'); $I->seeInShellOutput('message4: MESSAGE4 FROM SUITE-ENV1.'); } public function runTestForMultipleEnvironments(CliGuy $I) { $I->wantTo('check that multiple required environments are taken into account'); $I->amInPath('tests/data/sandbox'); $I->executeCommand('run messages MessageCest.php:multipleEnvRequired -vv --env env1'); $I->dontSeeInShellOutput('Multiple env given'); $I->executeCommand('run messages MessageCest.php:multipleEnvRequired -vv --env env2'); $I->dontSeeInShellOutput('Multiple env given'); $I->executeCommand('run messages MessageCest.php:multipleEnvRequired -vv --env env1,env2'); $I->seeInShellOutput('Multiple env given'); $I->executeCommand('run messages MessageCest.php:multipleEnvRequired -vv --env env2,env1'); $I->seeInShellOutput('Multiple env given'); } public function generateEnvConfig(CliGuy $I) { $I->amInPath('tests/data/sandbox'); $I->executeCommand('g:env firefox'); $I->seeInShellOutput('firefox config was created'); $I->seeFileFound('tests/_envs/firefox.yml'); } public function runEnvironmentForCept(CliGuy $I) { $I->amInPath('tests/data/sandbox'); $I->executeCommand('run messages --env email'); $I->seeInShellOutput('Test emails'); $I->dontSeeInShellOutput('Multiple env given'); $I->executeCommand('run messages --env env1'); $I->dontSeeInShellOutput('Test emails'); } public function showExceptionForUnconfiguredEnvironment(CliGuy $I) { $I->amInPath('tests/data/sandbox'); $I->executeCommand('run skipped NoEnvironmentCept --no-exit'); $I->seeInShellOutput("Environment nothing was not configured but used"); $I->seeInShellOutput('WARNING'); } public function environmentsFromSubfolders(CliGuy $I) { $I->amInPath('tests/data/sandbox'); $I->executeCommand('run messages MessageCest.php:allMessages -vv --env env3'); $I->seeInShellOutput('MESSAGE2 FROM ENV3'); } }
Save
cmd:
run