3 namespace Drupal\simpletest\Tests;
5 use Drupal\entity_test\Entity\EntityTest;
6 use Drupal\simpletest\WebTestBase;
9 * Tests batch operations during tests execution.
11 * This demonstrates that a batch will be successfully executed during module
12 * installation when running tests.
16 class SimpleTestInstallBatchTest extends WebTestBase {
23 public static $modules = ['simpletest', 'simpletest_test', 'entity_test'];
26 * Tests loading entities created in a batch in simpletest_test_install().
28 public function testLoadingEntitiesCreatedInBatch() {
29 $entity1 = EntityTest::load(1);
30 $this->assertNotNull($entity1, 'Successfully loaded entity 1.');
31 $entity2 = EntityTest::load(2);
32 $this->assertNotNull($entity2, 'Successfully loaded entity 2.');