You are here

public function PurgerDeleteFormTest::testDeletePurgerWhichDoesNotExist in Purge 8.3

Assert that deleting a purger that does not exist, passes silently.

File

modules/purge_ui/tests/src/Functional/Form/PurgerDeleteFormTest.php, line 94

Class

PurgerDeleteFormTest
Tests \Drupal\purge_ui\Form\PurgerDeleteForm.

Namespace

Drupal\Tests\purge_ui\Functional\Form

Code

public function testDeletePurgerWhichDoesNotExist() : void {
  $this
    ->drupalLogin($this->adminUser);
  $ajax = $this
    ->postAjaxForm([], 'Yes, delete this purger!', $this->routeParametersInvalid);
  $this
    ->assertAjaxCommandCloseModalDialog($ajax);
  $this
    ->assertAjaxCommandsTotal($ajax, 1);
}