mirror of
https://github.com/silverstripe/silverstripe-behat-extension
synced 2024-10-22 17:05:32 +02:00
Merge pull request #158 from robbieaverill/pulls/4.0/consistent-instance-method
API Consistent use of inst() naming across framework
This commit is contained in:
commit
47bebe6c3a
@ -22,7 +22,8 @@ matrix:
|
||||
before_script:
|
||||
- composer validate
|
||||
- composer install --dev --prefer-dist
|
||||
- composer require --update-with-dependencies silverstripe/framework:4.0.x-dev silverstripe/siteconfig:4.0.x-dev silverstripe/config:1.0.x-dev silverstripe/assets:1.0.x-dev silverstripe/versioned:1.0.x-dev --prefer-dist
|
||||
- composer require --prefer-dist --no-update symfony/config:^3.2 silverstripe/framework:4.0.x-dev silverstripe/siteconfig:4.0.x-dev silverstripe/config:1.0.x-dev silverstripe/assets:1.0.x-dev silverstripe/versioned:1.0.x-dev --prefer-dist
|
||||
- composer update
|
||||
- if [[ $PHPCS_TEST ]]; then pyrus install pear/PHP_CodeSniffer; fi
|
||||
- phpenv rehash
|
||||
|
||||
|
@ -32,7 +32,7 @@ class CoreInitializationPass implements CompilerPassInterface
|
||||
}
|
||||
|
||||
// Register all paths
|
||||
foreach (ModuleLoader::instance()->getManifest()->getModules() as $module) {
|
||||
foreach (ModuleLoader::inst()->getManifest()->getModules() as $module) {
|
||||
$container->setParameter('paths.modules.'.$module->getShortName(), $module->getPath());
|
||||
$composerName = $module->getComposerName();
|
||||
if ($composerName) {
|
||||
|
@ -19,7 +19,7 @@ trait ModuleCommandTrait
|
||||
if (strpos($name, '@') === 0) {
|
||||
$name = substr($name, 1);
|
||||
}
|
||||
$module = ModuleLoader::instance()->getManifest()->getModule($name);
|
||||
$module = ModuleLoader::inst()->getManifest()->getModule($name);
|
||||
if (!$module) {
|
||||
throw new InvalidArgumentException("No module $name installed");
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user