You are here

public function PaymentTest::testMethodManager in Payment 8.2

@covers ::methodManager

File

tests/src/Unit/PaymentTest.php, line 47

Class

PaymentTest
@coversDefaultClass \Drupal\payment\Payment

Namespace

Drupal\Tests\payment\Unit

Code

public function testMethodManager() {
  $container = new Container();
  $method_manager = $this
    ->createMock(PaymentMethodManagerInterface::class);
  $container
    ->set('plugin.manager.payment.method', $method_manager);
  \Drupal::setContainer($container);
  $this
    ->assertSame($method_manager, Payment::methodManager());
}