The "stash" lock was used to shove .gitignore'd files under the rug
so that they would not interfere with a pure copy of the app.
Vendor files may be ignored in the app, so for performance, the
"stash" lock has been deactivated. Vendor files no longer need to
be downloaded each time the test runs.
The "commit" lock now includes all ignored files so that tests
are run with the files as they are.
Added a guard to GitPreparer::unsetVcsInProgress() to prevent doing a
`git reset` when there are no test locks present.
Otherwise, the uncommitted changes in the app will be removed by the
shutdown feature introduced in 952c6e5890daa36236be675d8c4f21cecabc1fe7.
Deployers, a concept unique to this repository, are now more separated
from Codeception modules.
This commit adds NoopDeployer, LocalDeployer, and SFTPDeployer to
address the three deployment target types in use by testers today.
The changes are backwards-incompatible because the structure of
config.sample.yml has changed, and all testers need to change their
config.yml or config.local.yml to continue testing. The reason for this
change is that the section "manual" no longer makes sense now that
Deployers are on a spectrum of automation levels.
The subsections under "manual" have been broken out into the root level.
The "db_dump" section has been merged into the new "db" root section.
There is a new "fs" root section used by the SFTP Deployer.
Other changes, enhancements, and bugfixes:
* cPanelDeployer no longer downgrades to "manual" mode when credentials
are missing or an unsupported component is requested. It now throws an
exception.
* Deployer::unlinkAppFile() was implemented for acceptance tests out of
necessity because the app requires a configuration file to be deleted
before re-running the app's installer.
* If a Deployer subclass does not implement the unlinkAppFile() method,
tests that depend on the method will be skipped gracefully.
* DeployerFactory now has a better autoload mechanism.
* A logical error in lib/config.php prevented missing nested array items
from using their default values.
* The Base Helper no longer pointlessly caches the DelayedDb module
* _bootstrap.php serializes the config.yml params into a global constant
so that the DeployerFactory can freely access the information.
- MOD: Renamed lib/deployers/cpanel_deployer.php to
lib/deployers/cPanelDeployer.php
- MOD: Moved responsibility of reconfiguring Codeception modules to the
deployers.
- NEW: Abstract class Deployer to standardize the interface to Deployers
- NEW: Acceptance tests now support unlinkE107ConfigFromTestEnvironment
- MOD: Removed null checks for the Deployer in the Base Module
- MOD: Improved public method naming in the Base Module
- MOD: DeployerFactory always returns a Deployer implementation now.
- MOD: InstallCest always clears out the e107_config.php file before
each test.
- MOD: Reduced code duplication in ./lib/config.php
- MOD: Replaced PHP 7.1 samples with PHP 7.2 samples in README.md
- NEW: ./config.sample.yml now supports customized database dumps, which
affects the Codeception database populator
- NEW: Code coverage reports now take into account the configured
`app_path`, which obviates a separate codeception.sample.yml file
and reduces the complexity in setting up this test harness
@CaMer0n and @SimSync: I'm aware that you previously needed a separate
codeception.yml file because the coverage reports didn't use the
`app_path` from `config.yml`. This has been fixed. I'd like to keep just
one place for custom configurations (config.yml) so that we can keep
tests reproducible and avoid inconsistencies if/when codeception.yml
gets updated in the future.
Parsing bug deleted all MariaDB users and databases that were not in the
active tests list. Now, cPanelDeployer will only delete the MariaDB
users and databases that are expired and leave those that are not part
of the testing suite alone.
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()
Refactored by extracting code common to all suites to \Helper\Base
New \Helper\DelayedDb helper to delay initialization so that a new DSN,
username, and password can be loaded in dynamically for automatic
database provisioning. Should still be compatible with manual database
information in codeception.yml