comparison core/modules/taxonomy/src/Tests/TaxonomyTestBase.php @ 0:4c8ae668cc8c

Initial import (non-working)
author Chris Cannam
date Wed, 29 Nov 2017 16:09:58 +0000
parents
children 129ea1e6d783
comparison
equal deleted inserted replaced
-1:000000000000 0:4c8ae668cc8c
1 <?php
2
3 namespace Drupal\taxonomy\Tests;
4
5 @trigger_error(__NAMESPACE__ . '\TaxonomyTestBase is deprecated in Drupal 8.4.0 and will be removed before Drupal 9.0.0. Instead, use \Drupal\Tests\taxonomy\Functional\TaxonomyTestBase', E_USER_DEPRECATED);
6
7 use Drupal\field\Tests\EntityReference\EntityReferenceTestTrait;
8 use Drupal\simpletest\WebTestBase;
9 use Drupal\Tests\taxonomy\Functional\TaxonomyTestTrait;
10
11 /**
12 * Provides common helper methods for Taxonomy module tests.
13 *
14 * @deprecated Scheduled for removal in Drupal 9.0.0.
15 * Use \Drupal\Tests\taxonomy\Functional\TaxonomyTestBase instead.
16 */
17 abstract class TaxonomyTestBase extends WebTestBase {
18
19 use TaxonomyTestTrait;
20 use EntityReferenceTestTrait;
21
22 /**
23 * Modules to enable.
24 *
25 * @var array
26 */
27 public static $modules = ['taxonomy', 'block'];
28
29 /**
30 * {@inheritdoc}
31 */
32 protected function setUp() {
33 parent::setUp();
34 $this->drupalPlaceBlock('system_breadcrumb_block');
35
36 // Create Basic page and Article node types.
37 if ($this->profile != 'standard') {
38 $this->drupalCreateContentType(['type' => 'article', 'name' => 'Article']);
39 }
40 }
41
42 }