public function RelationTestBase::setUp in Relation 8.2
Same name and namespace in other branches
- 8 src/Tests/RelationTestBase.php \Drupal\relation\Tests\RelationTestBase::setUp()
Sets up a Drupal site for running functional and integration tests.
Installs Drupal with the installation profile specified in \Drupal\simpletest\WebTestBase::$profile into the prefixed database.
Afterwards, installs any additional modules specified in the static \Drupal\simpletest\WebTestBase::$modules property of each class in the class hierarchy.
After installation all caches are flushed and several configuration values are reset to the values of the parent site executing the test, since the default values may be incompatible with the environment in which tests are being executed.
Overrides WebTestBase::setUp
5 calls to RelationTestBase::setUp()
- RelationAPITest::setUp in src/
Tests/ RelationAPITest.php - Sets up a Drupal site for running functional and integration tests.
- RelationEntityCollectorTest::setUp in relation_entity_collector/
src/ Tests/ RelationEntityCollectorTest.php - Sets up a Drupal site for running functional and integration tests.
- RelationRulesTest::setUp in src/
Tests/ RelationRulesTest.php - Sets up a Drupal site for running functional and integration tests.
- RelationUITest::setUp in src/
Tests/ RelationUITest.php - Sets up a Drupal site for running functional and integration tests.
- RelationViewsTest::setUp in src/
Tests/ RelationViewsTest.php - Sets up a Drupal site for running functional and integration tests.
5 methods override RelationTestBase::setUp()
- RelationAPITest::setUp in src/
Tests/ RelationAPITest.php - Sets up a Drupal site for running functional and integration tests.
- RelationEntityCollectorTest::setUp in relation_entity_collector/
src/ Tests/ RelationEntityCollectorTest.php - Sets up a Drupal site for running functional and integration tests.
- RelationRulesTest::setUp in src/
Tests/ RelationRulesTest.php - Sets up a Drupal site for running functional and integration tests.
- RelationUITest::setUp in src/
Tests/ RelationUITest.php - Sets up a Drupal site for running functional and integration tests.
- RelationViewsTest::setUp in src/
Tests/ RelationViewsTest.php - Sets up a Drupal site for running functional and integration tests.
File
- src/
Tests/ RelationTestBase.php, line 31
Class
- RelationTestBase
- Provides common helper methods for Taxonomy module tests.
Namespace
Drupal\relation\TestsCode
public function setUp() {
parent::setUp();
// Create Basic page and Article node types.
if ($this->profile != 'standard') {
$this
->drupalCreateContentType([
'type' => 'page',
'name' => 'Basic page',
]);
$this
->drupalCreateContentType([
'type' => 'article',
'name' => 'Article',
]);
}
// Defines entities.
$this
->createRelationNodes();
$this
->createRelationUsers();
// Defines relation types.
$this
->createRelationTypes();
// Defines end points.
$this
->createRelationEndPoints();
// Defines relations.
$this
->createRelationSymmetric();
$this
->createRelationDirectional();
$this
->createRelationOctopus();
$this
->createRelationUnary();
}