Skip to content

Commit

Permalink
Use willReturnMap in MapServiceTest for ConfigManager
Browse files Browse the repository at this point in the history
  • Loading branch information
sfroemkenjw committed Oct 13, 2023
1 parent ca7191e commit 4098331
Showing 1 changed file with 18 additions and 19 deletions.
37 changes: 18 additions & 19 deletions Tests/Functional/Service/MapServiceTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -77,28 +77,27 @@ protected function setUp(): void
$this->configurationManagerMock
->expects(self::atLeastOnce())
->method('getConfiguration')
->with(
ConfigurationManagerInterface::CONFIGURATION_TYPE_FRAMEWORK,
'Maps2',
'Maps2'
)
->willReturn([
'view' => [
'layoutRootPaths' => [],
'partialRootPaths' => [
'EXT:maps2/Tests/Functional/Fixtures/Partials',
->willReturnMap([
[
ConfigurationManagerInterface::CONFIGURATION_TYPE_FRAMEWORK,
'Maps2',
'Maps2',
[
'view' => [
'layoutRootPaths' => [],
'partialRootPaths' => [
'EXT:maps2/Tests/Functional/Fixtures/Partials',
],
],
],
],
[
ConfigurationManagerInterface::CONFIGURATION_TYPE_SETTINGS,
'Maps2',
'Maps2',
[]
],
]);
$this->configurationManagerMock
->expects(self::atLeastOnce())
->method('getConfiguration')
->with(
ConfigurationManagerInterface::CONFIGURATION_TYPE_SETTINGS,
'Maps2',
'Maps2'
)
->willReturn([]);

// Replace default template to prevent calling cache VHs. They check against FE
$this->extConfMock = $this->createMock(ExtConf::class);
Expand Down

0 comments on commit 4098331

Please sign in to comment.