mirror of
https://github.com/silverstripe/silverstripe-behat-extension
synced 2024-10-22 17:05:32 +02:00
API Consistent use of inst() naming across framework
This commit is contained in:
parent
18e6b9297e
commit
8167d14b09
@ -22,7 +22,8 @@ matrix:
|
|||||||
before_script:
|
before_script:
|
||||||
- composer validate
|
- composer validate
|
||||||
- composer install --dev --prefer-dist
|
- 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
|
- if [[ $PHPCS_TEST ]]; then pyrus install pear/PHP_CodeSniffer; fi
|
||||||
- phpenv rehash
|
- phpenv rehash
|
||||||
|
|
||||||
|
@ -32,7 +32,7 @@ class CoreInitializationPass implements CompilerPassInterface
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Register all paths
|
// 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());
|
$container->setParameter('paths.modules.'.$module->getShortName(), $module->getPath());
|
||||||
$composerName = $module->getComposerName();
|
$composerName = $module->getComposerName();
|
||||||
if ($composerName) {
|
if ($composerName) {
|
||||||
|
@ -19,7 +19,7 @@ trait ModuleCommandTrait
|
|||||||
if (strpos($name, '@') === 0) {
|
if (strpos($name, '@') === 0) {
|
||||||
$name = substr($name, 1);
|
$name = substr($name, 1);
|
||||||
}
|
}
|
||||||
$module = ModuleLoader::instance()->getManifest()->getModule($name);
|
$module = ModuleLoader::inst()->getManifest()->getModule($name);
|
||||||
if (!$module) {
|
if (!$module) {
|
||||||
throw new InvalidArgumentException("No module $name installed");
|
throw new InvalidArgumentException("No module $name installed");
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user