Updated all the contrib modules to their latest versions.
[yaffs-website] / web / modules / contrib / admin_toolbar / tests / src / Functional / AdminToolbarAlterTest.php
1 <?php
2
3 namespace Drupal\Tests\admin_toolbar\Functional;
4
5 use Drupal\Tests\BrowserTestBase;
6
7 /**
8  * Test the existence of Admin Toolbar module.
9  *
10  * @group admin_toolbar
11  */
12 class AdminToolbarAlterTest extends BrowserTestBase {
13
14   /**
15    * Modules to enable.
16    *
17    * @var array
18    */
19   protected static $modules = [
20     'toolbar',
21     'breakpoint',
22     'admin_toolbar',
23   ];
24
25   /**
26    * A test user with permission to access the administrative toolbar.
27    *
28    * @var \Drupal\user\UserInterface
29    */
30   protected $adminUser;
31
32   /**
33    * {@inheritdoc}
34    */
35   protected function setUp() {
36     parent::setUp();
37
38     // Create and log in an administrative user.
39     $this->adminUser = $this->drupalCreateUser([
40       'access toolbar',
41       'access administration pages',
42     ]);
43     $this->drupalLogin($this->adminUser);
44   }
45
46   /**
47    * Tests for a the hover of sub menus.
48    */
49   public function testAdminToolbar() {
50     // Assert that expanded links are present in the HTML.
51     $this->assertRaw('class="toolbar-icon toolbar-icon-user-admin-index"');
52   }
53
54 }