You are here

protected function ManageTeamAppsApiProductAccessTest::tearDown in Apigee Edge 8

Overrides WebDriverTestBase::tearDown

File

modules/apigee_edge_teams/tests/src/FunctionalJavascript/ManageTeamAppsApiProductAccessTest.php, line 162

Class

ManageTeamAppsApiProductAccessTest
Extra validation for API product access on team app forms.

Namespace

Drupal\Tests\apigee_edge_teams\FunctionalJavascript

Code

protected function tearDown() {
  if ($this->account !== NULL) {
    try {
      $this->account
        ->delete();
    } catch (\Exception $exception) {
      $this
        ->logException($exception);
    }
  }
  if ($this->team !== NULL) {
    try {
      $this->team
        ->delete();
    } catch (\Exception $exception) {
      $this
        ->logException($exception);
    }
  }
  if ($this->publicProduct !== NULL) {
    try {
      $this->publicProduct
        ->delete();
    } catch (\Exception $exception) {
      $this
        ->logException($exception);
    }
  }
  if ($this->privateProduct !== NULL) {
    try {
      $this->privateProduct
        ->delete();
    } catch (\Exception $exception) {
      $this
        ->logException($exception);
    }
  }
  if ($this->internalProduct !== NULL) {
    try {
      $this->internalProduct
        ->delete();
    } catch (\Exception $exception) {
      $this
        ->logException($exception);
    }
  }
  parent::tearDown();
}