public function ContentEntityNormalizerTest::createMockForContentHubAdminConfig in Acquia Content Hub 8
Returns a fake ContentHubAdminConfig object.
Return value
\Drupal\Core\Config\ImmutableConfig The fake config.
1 call to ContentEntityNormalizerTest::createMockForContentHubAdminConfig()
- ContentEntityNormalizerTest::setUp in tests/
src/ Unit/ Normalizer/ ContentEntityNormalizerTest.php
File
- tests/
src/ Unit/ Normalizer/ ContentEntityNormalizerTest.php, line 931
Class
- ContentEntityNormalizerTest
- PHPUnit test for the ContentEntityNormalizer class.
Namespace
Drupal\Tests\acquia_contenthub\Unit\NormalizerCode
public function createMockForContentHubAdminConfig() {
$contenthub_admin_config = $this
->getMockBuilder('Drupal\\Core\\Config\\ImmutableConfig')
->disableOriginalConstructor()
->setMethods([
'get',
])
->getMockForAbstractClass();
$contenthub_admin_config
->method('get')
->with('origin')
->willReturn('test-origin');
return $contenthub_admin_config;
}