function CurrencyLocaleImportFormTest::testCreate in Currency 8.3
Same name in this branch
- 8.3 tests/src/Unit/Controller/CurrencyLocaleImportFormTest.php \Drupal\Tests\currency\Unit\Controller\CurrencyLocaleImportFormTest::testCreate()
- 8.3 tests/src/Unit/Form/CurrencyLocaleImportFormTest.php \Drupal\Tests\currency\Unit\Form\CurrencyLocaleImportFormTest::testCreate()
@covers ::create @covers ::__construct
File
- tests/
src/ Unit/ Controller/ CurrencyLocaleImportFormTest.php, line 78
Class
- CurrencyLocaleImportFormTest
- @coversDefaultClass \Drupal\currency\Form\CurrencyLocaleImportForm
Namespace
Drupal\Tests\currency\Unit\ControllerCode
function testCreate() {
$container = $this
->createMock(ContainerInterface::class);
$map = [
[
'currency.config_importer',
ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE,
$this->configImporter,
],
[
'currency.form_helper',
ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE,
$this->formHelper,
],
[
'string_translation',
ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE,
$this->stringTranslation,
],
];
$container
->expects($this
->any())
->method('get')
->willReturnMap($map);
$sut = CurrencyLocaleImportForm::create($container);
$this
->assertInstanceOf(CurrencyLocaleImportForm::class, $sut);
}