You are here

public function ApiProductTest::testSetScopes in Apigee Edge 8

Test setting scopes.

File

tests/src/Unit/Entity/ApiProductTest.php, line 61

Class

ApiProductTest
Test ApiProductTest class.

Namespace

Drupal\Tests\apigee_edge\Unit\Entity

Code

public function testSetScopes() {
  $scopes_expected = [
    'scope1',
    'scope2',
  ];
  $this->apiProduct
    ->setScopes(...$scopes_expected);
  $scopes_actual = $this->apiProduct
    ->getScopes();
  $this
    ->assertArrayEquals($scopes_expected, $scopes_actual);
}