You are here

public function Update8401Test::testUpdate in Lightning API 8.4

Tests that the update uninstalls simple_oauth_extras.

File

tests/src/Functional/Update8401Test.php, line 34

Class

Update8401Test
Tests the Lightning API update to uninstall Simple OAuth Extras.

Namespace

Drupal\Tests\lightning_api\Functional

Code

public function testUpdate() {

  // openapi_redoc is long gone, so prevent the update system from complaining
  // about that.
  $this->container
    ->get('keyvalue')
    ->get('system.schema')
    ->delete('openapi_redoc');
  $this
    ->assertTrue($this->container
    ->get('module_handler')
    ->moduleExists('simple_oauth_extras'));
  $this
    ->runUpdates();
  $this
    ->assertFalse($this->container
    ->get('module_handler')
    ->moduleExists('simple_oauth_extras'));
}