mirror of
https://github.com/hauke68/Magallanes.git
synced 2026-08-29 18:48:56 +02:00
[Nostromo] Refactor config load
This commit is contained in:
@@ -21,7 +21,6 @@ class DumpCommandTest extends TestCase
|
||||
public function testConfigDumpTermination()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../../Resources/basic.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('config:dump');
|
||||
|
||||
@@ -21,7 +21,6 @@ class EnvironmentsCommandTest extends TestCase
|
||||
public function testConfigDumpTermination()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../../Resources/basic.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('config:environments');
|
||||
|
||||
@@ -21,7 +21,6 @@ class DeployCommandMiscTasksTest extends TestCase
|
||||
public function testSymfonyEnvironmentConfiguration()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/symfony-envconf.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('deploy');
|
||||
@@ -54,7 +53,6 @@ class DeployCommandMiscTasksTest extends TestCase
|
||||
public function testComposerFlags()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/composer.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('deploy');
|
||||
@@ -85,7 +83,6 @@ class DeployCommandMiscTasksTest extends TestCase
|
||||
public function testInvalidTaskName()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/invalid-task.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('deploy');
|
||||
@@ -101,7 +98,6 @@ class DeployCommandMiscTasksTest extends TestCase
|
||||
public function testBrokenGitBranch()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/broken-git-branch.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('deploy');
|
||||
@@ -120,7 +116,6 @@ class DeployCommandMiscTasksTest extends TestCase
|
||||
public function testBrokenGitCheckout()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/broken-git-branch.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('deploy');
|
||||
@@ -139,7 +134,6 @@ class DeployCommandMiscTasksTest extends TestCase
|
||||
public function testBrokenGitUpdate()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/broken-git-branch.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('deploy');
|
||||
|
||||
@@ -21,7 +21,6 @@ class DeployCommandMiscTest extends TestCase
|
||||
public function testDeploymentWithNoHosts()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/no-hosts.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('deploy');
|
||||
@@ -40,7 +39,6 @@ class DeployCommandMiscTest extends TestCase
|
||||
public function testDeploymentWithSudo()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/testhost-sudo.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('deploy');
|
||||
@@ -79,7 +77,6 @@ class DeployCommandMiscTest extends TestCase
|
||||
public function testDeploymentWithBranchOverwrite()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/testhost-without-releases.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('deploy');
|
||||
@@ -117,8 +114,6 @@ class DeployCommandMiscTest extends TestCase
|
||||
public function testDeploymentWithCustomTask()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/testhost-custom-task.yml');
|
||||
$application->configure();
|
||||
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('deploy');
|
||||
@@ -151,7 +146,6 @@ class DeployCommandMiscTest extends TestCase
|
||||
public function testDeploymentWithErrorTaskCommands()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/testhost-with-error.yml');
|
||||
$application->configure();
|
||||
|
||||
$application->getRuntime()->setReleaseId('20170101015120');
|
||||
|
||||
@@ -193,7 +187,6 @@ class DeployCommandMiscTest extends TestCase
|
||||
public function testDeploymentWithFailingPostDeployTaskCommands()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/testhost-with-postdeploy-error.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('deploy');
|
||||
@@ -229,7 +222,6 @@ class DeployCommandMiscTest extends TestCase
|
||||
public function testDeploymentWithSkippingTask()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/testhost-skipping.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('deploy');
|
||||
|
||||
@@ -21,7 +21,6 @@ class DeployCommandWithReleasesTest extends TestCase
|
||||
public function testDeploymentWithReleasesCommands()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/testhost.yml');
|
||||
$application->configure();
|
||||
|
||||
$application->getRuntime()->setReleaseId('20170101015120');
|
||||
|
||||
@@ -72,7 +71,6 @@ class DeployCommandWithReleasesTest extends TestCase
|
||||
public function testDeploymentWithoutReleasesTarPrepare()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/testhost-force-tar1.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('deploy');
|
||||
@@ -88,7 +86,6 @@ class DeployCommandWithReleasesTest extends TestCase
|
||||
public function testDeploymentWithoutReleasesTarCopy()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/testhost-force-tar2.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('deploy');
|
||||
@@ -104,7 +101,6 @@ class DeployCommandWithReleasesTest extends TestCase
|
||||
public function testDeploymentWithoutReleasesTarCleanup()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/testhost-force-tar3.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('deploy');
|
||||
@@ -120,7 +116,6 @@ class DeployCommandWithReleasesTest extends TestCase
|
||||
public function testDeploymentFailCopyCommands()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/testhost-fail-copy-tar.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('deploy');
|
||||
@@ -136,7 +131,6 @@ class DeployCommandWithReleasesTest extends TestCase
|
||||
public function testDeploymentWithoutReleasesForceRelease()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/testhost-force-release.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('deploy');
|
||||
@@ -152,7 +146,6 @@ class DeployCommandWithReleasesTest extends TestCase
|
||||
public function testDeploymentFailToExtract()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/testhost.yml');
|
||||
$application->configure();
|
||||
|
||||
$application->getRuntime()->setReleaseId('20170101015120');
|
||||
|
||||
@@ -195,7 +188,6 @@ class DeployCommandWithReleasesTest extends TestCase
|
||||
public function testDeploymentFailToCopy()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/testhost.yml');
|
||||
$application->configure();
|
||||
|
||||
$application->getRuntime()->setReleaseId('20170101015120');
|
||||
|
||||
@@ -237,7 +229,6 @@ class DeployCommandWithReleasesTest extends TestCase
|
||||
public function testDeploymentFailCleanup()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/testhost.yml');
|
||||
$application->configure();
|
||||
|
||||
$application->getRuntime()->setReleaseId('20170101015120');
|
||||
|
||||
@@ -291,7 +282,6 @@ class DeployCommandWithReleasesTest extends TestCase
|
||||
public function testDeploymentFailMidway()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/testhost.yml');
|
||||
$application->configure();
|
||||
|
||||
$application->getRuntime()->setReleaseId('20170101015120');
|
||||
|
||||
|
||||
@@ -21,7 +21,6 @@ class DeployCommandWithoutReleasesTest extends TestCase
|
||||
public function testDeploymentWithoutReleasesCommands()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/testhost-without-releases.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('deploy');
|
||||
@@ -59,7 +58,6 @@ class DeployCommandWithoutReleasesTest extends TestCase
|
||||
public function testDeploymentFailMidway()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/testhost-without-releases.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('deploy');
|
||||
|
||||
@@ -21,7 +21,6 @@ class ListCommandTest extends TestCase
|
||||
public function testListReleasesCommands()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../../Resources/testhost.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('releases:list');
|
||||
@@ -49,7 +48,6 @@ class ListCommandTest extends TestCase
|
||||
public function testListReleasesWithInvalidEnvironment()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../../Resources/testhost.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('releases:list');
|
||||
@@ -65,7 +63,6 @@ class ListCommandTest extends TestCase
|
||||
public function testListReleasesWithoutReleases()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../../Resources/testhost-without-releases.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('releases:list');
|
||||
@@ -81,7 +78,6 @@ class ListCommandTest extends TestCase
|
||||
public function testFailToGetCurrentRelease()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../../Resources/testhost-fail-get-current.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('releases:list');
|
||||
@@ -97,7 +93,6 @@ class ListCommandTest extends TestCase
|
||||
public function testNoReleasesAvailable()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../../Resources/testhost-no-releases.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('releases:list');
|
||||
@@ -112,7 +107,6 @@ class ListCommandTest extends TestCase
|
||||
public function testFailGetReleases()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../../Resources/testhost-fail-get-releases.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('releases:list');
|
||||
@@ -128,7 +122,6 @@ class ListCommandTest extends TestCase
|
||||
public function testNoHosts()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../../Resources/testhost-no-hosts.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('releases:list');
|
||||
|
||||
@@ -21,7 +21,6 @@ class RollbackCommandTest extends TestCase
|
||||
public function testRollbackReleaseCommands()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../../Resources/testhost.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('releases:rollback');
|
||||
@@ -49,7 +48,6 @@ class RollbackCommandTest extends TestCase
|
||||
public function testRollbackReleaseWithInvalidEnvironment()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../../Resources/testhost.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('releases:rollback');
|
||||
@@ -65,7 +63,6 @@ class RollbackCommandTest extends TestCase
|
||||
public function testRollbackReleaseWithoutReleases()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../../Resources/testhost-without-releases.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('releases:rollback');
|
||||
@@ -81,7 +78,6 @@ class RollbackCommandTest extends TestCase
|
||||
public function testRollbackReleaseNotAvailable()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../../Resources/testhost-not-have-release.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('releases:rollback');
|
||||
|
||||
@@ -22,7 +22,6 @@ class VersionCommandTest extends TestCase
|
||||
public function testVersionOutput()
|
||||
{
|
||||
$application = new MageApplicationMockup(__DIR__ . '/../../Resources/basic.yml');
|
||||
$application->configure();
|
||||
|
||||
/** @var AbstractCommand $command */
|
||||
$command = $application->find('version');
|
||||
|
||||
Reference in New Issue
Block a user