Skip to content

Commit

Permalink
Bug fix modules that extend the OxidEsales\Eshop\Core\Cache\Generic\C…
Browse files Browse the repository at this point in the history
…ache class are considered.
  • Loading branch information
TumTum committed May 13, 2019
1 parent 2fe0cac commit 2c6f837
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/Oxrun/Command/Cache/ClearCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -141,10 +141,10 @@ protected function enterpriseCache(OutputInterface $output)
}

try {
Registry::get('\OxidEsales\Eshop\Core\Cache\Generic\Cache')->flush();
Registry::get('OxidEsales\Eshop\Core\Cache\Generic\Cache')->flush();
$output->writeln('<info>Generic\Cache is cleared</info>');

Registry::get('\OxidEsales\Eshop\Core\Cache\DynamicContent\ContentCache')->reset(true);
Registry::get('OxidEsales\Eshop\Core\Cache\DynamicContent\ContentCache')->reset(true);
$output->writeln('<info>DynamicContent\Cache is cleared</info>');

} catch (\Exception $e) {
Expand Down
4 changes: 2 additions & 2 deletions tests/Oxrun/Command/Cache/ClearCommandTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ protected function mockEEGenericCacheClass()
$genericCache = $this->prophesize(GenericCache::class);

Registry::set(\OxidEsales\Facts\Facts::class, $facts->reveal());
Registry::set('\OxidEsales\Eshop\Core\Cache\Generic\Cache', $genericCache->reveal());
Registry::set('OxidEsales\Eshop\Core\Cache\Generic\Cache', $genericCache->reveal());

return [$facts, $genericCache];
}
Expand All @@ -136,7 +136,7 @@ protected function mockEEGenericCacheAndDynamicContentClass()
list($facts, $genericCache) = $this->mockEEGenericCacheClass();

$dynamicContentCache = $this->prophesize(DynamicContentCache::class);
Registry::set('\OxidEsales\Eshop\Core\Cache\DynamicContent\ContentCache', $dynamicContentCache->reveal());
Registry::set('OxidEsales\Eshop\Core\Cache\DynamicContent\ContentCache', $dynamicContentCache->reveal());

return [$facts, $genericCache, $dynamicContentCache];
}
Expand Down

0 comments on commit 2c6f837

Please sign in to comment.