You are here

protected function MatomoPhpFilterTest::setUp in Matomo Analytics 8

Overrides BrowserTestBase::setUp

File

tests/src/Functional/MatomoPhpFilterTest.php, line 32

Class

MatomoPhpFilterTest
Test php filter functionality of Matomo module.

Namespace

Drupal\Tests\matomo\Functional

Code

protected function setUp() {
  parent::setUp();

  // Administrator with all permissions.
  $permissions_admin_user = [
    'access administration pages',
    'administer matomo',
    'use php for matomo tracking visibility',
  ];
  $this->admin_user = $this
    ->drupalCreateUser($permissions_admin_user);

  // Administrator who cannot configure tracking visibility with PHP.
  $permissions_delegated_admin_user = [
    'access administration pages',
    'administer matomo',
  ];
  $this->delegated_admin_user = $this
    ->drupalCreateUser($permissions_delegated_admin_user);
}