public function PaymentMethodConfigurationTest::testSetOwner in Payment 8.2
@covers ::setOwner
@depends testGetOwnerId
File
- tests/
src/ Unit/ Entity/ PaymentMethodConfigurationTest.php, line 167
Class
- PaymentMethodConfigurationTest
- @coversDefaultClass \Drupal\payment\Entity\PaymentMethodConfiguration
Namespace
Drupal\Tests\payment\Unit\EntityCode
public function testSetOwner() {
$id = mt_rand();
$owner = $this
->createMock(UserInterface::class);
$owner
->expects($this
->atLeastOnce())
->method('id')
->willReturn($id);
$this->sut
->setOwner($owner);
$this
->assertSame($id, $this->sut
->getOwnerId());
}