You are here

function ResumeContextTest::testCreate in Payment 8.2

@covers ::create @covers ::__construct

File

modules/payment_reference/tests/src/Unit/Controller/ResumeContextTest.php, line 56

Class

ResumeContextTest
@coversDefaultClass \Drupal\payment_reference\Controller\ResumeContext

Namespace

Drupal\Tests\payment_reference\Unit\Controller

Code

function testCreate() {
  $container = $this
    ->createMock(ContainerInterface::class);
  $map = array(
    array(
      'current_user',
      ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE,
      $this->currentUser,
    ),
    array(
      'string_translation',
      ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE,
      $this->stringTranslation,
    ),
  );
  $container
    ->expects($this
    ->any())
    ->method('get')
    ->willReturnMap($map);
  $sut = ResumeContext::create($container);
  $this
    ->assertInstanceOf(ResumeContext::class, $sut);
}