MigrationStatusPageTest.php in Lightning Workflow 8.2
File
modules/lightning_scheduler/tests/src/Functional/MigrationStatusPageTest.php
View source
<?php
namespace Drupal\Tests\lightning_scheduler\Functional;
class MigrationStatusPageTest extends MigrationTestBase {
public function test() {
parent::test();
$assert = $this
->assertSession();
$text = 'Some content has not yet been migrated into the new base fields installed by Lightning Scheduler.';
$url = parse_url($this
->getSession()
->getCurrentUrl(), PHP_URL_PATH);
$this
->assertNotEmpty($url);
$this
->drupalGet('/admin/reports/status');
$assert
->pageTextContains($text);
$assert
->linkByHrefExists($url);
$this->container
->get('lightning_scheduler.migrator')
->setMigrations([]);
$this
->getSession()
->reload();
$assert
->pageTextNotContains($text);
}
}