mirror of
https://github.com/e107inc/e107.git
synced 2025-10-13 14:04:51 +02:00
e107 is now ready for fully automated testing on all three test suites: * Acceptance * Functional * Unit New features: * cPanelDeployer adds a cPanel Remote MySQL access host * e107 database dump importer * Unit tests now load e107 Fixes: * Test prefixes now only use characters valid for MySQL/MariaDB without escaping * Refactored a bunch of things * All existing tests pass now Changes: * Deployers now provided by \Helper\DeployerFactory * Added Twig templating for generating e107_config.php for testing * cPanelDeployer now outputs to codecept_debug()
26 lines
555 B
PHP
26 lines
555 B
PHP
<?php
|
|
namespace Helper;
|
|
include_once(__DIR__ . "/../../../lib/deployers/cpanel_deployer.php");
|
|
|
|
// here you can define custom actions
|
|
// all public methods declared in helper class will be available in $I
|
|
|
|
class DeployerFactory extends \Codeception\Module
|
|
{
|
|
public function create()
|
|
{
|
|
return $this->createFromSecrets($this->config['secrets']);
|
|
}
|
|
|
|
public function createFromSecrets($secrets)
|
|
{
|
|
$deployer = null;
|
|
if ($secrets['cpanel']['enabled'] === '1')
|
|
{
|
|
$deployer = new \cPanelDeployer($secrets['cpanel']);
|
|
}
|
|
return $deployer;
|
|
}
|
|
|
|
}
|