Skip to content

Commit

Permalink
Additional Travis CI builds fixes: fix mistake in .travis.yml which b…
Browse files Browse the repository at this point in the history
…roke everything, fix trouble caused integration tests failures on PHP 5.5/5.6, speed up composer install by bot preferring source, eliminate notice due to empty config value passed to @magentoConfigFixture
  • Loading branch information
orlangur committed Dec 14, 2014
1 parent 4596640 commit ddb82b0
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
3 changes: 1 addition & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,7 @@ before_script:
# Change memory_limit for travis
- echo 'memory_limit = -1' >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
- phpenv rehash;
- composer install --no-interaction --prefer-source --dev
- cd ..
- composer install --no-interaction --dev
script:
# Unit tests
- sh -c "if [ '$TEST_SUITE' = 'unit' ]; then ./vendor/bin/phpunit -c dev/tests/unit/phpunit.xml.dist; fi"
Expand Down
4 changes: 3 additions & 1 deletion app/code/Magento/Directory/Helper/Data.php
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,9 @@ public function getRegionJson()
];
}
$json = $this->_coreHelper->jsonEncode($regions);

if ($json === false) {
$json = 'false';
}
$this->_configCacheType->save($json, $cacheKey);
}
$this->_regionJson = $json;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,8 @@ protected function _assignConfigData(\PHPUnit_Framework_TestCase $test)
if (preg_match('/^.+?(?=_store\s)/', $configPathAndValue, $matches)) {
/* Store-scoped config value */
$storeCode = $matches[0] != 'current' ? $matches[0] : null;
list(, $configPath, $requiredValue) = preg_split('/\s+/', $configPathAndValue, 3);
$parts = preg_split('/\s+/', $configPathAndValue, 3);
list(, $configPath, $requiredValue) = $parts + ['', '', ''];
$originalValue = $this->_getConfigValue($configPath, $storeCode);
$this->_storeConfigValues[$storeCode][$configPath] = $originalValue;
$this->_setConfigValue($configPath, $requiredValue, $storeCode);
Expand Down

0 comments on commit ddb82b0

Please sign in to comment.