You are here

protected function WebAssertArgumentsTest::setUp in Drupal 10

Same name and namespace in other branches
  1. 9 core/tests/Drupal/Tests/Core/Assert/WebAssertArgumentsTest.php \Drupal\Tests\Core\Assert\WebAssertArgumentsTest::setUp()

Overrides UnitTestCase::setUp

File

core/tests/Drupal/Tests/Core/Assert/WebAssertArgumentsTest.php, line 45

Class

WebAssertArgumentsTest
Tests that calling WebAssert methods with extra arguments leads to errors.

Namespace

Drupal\Tests\Core\Assert

Code

protected function setUp() : void {
  parent::setUp();
  $this->page = $this
    ->prophesize(DocumentElement::class);
  $this->session = $this
    ->prophesize(Session::class);
  $this->session
    ->getPage()
    ->willReturn($this->page
    ->reveal());
  $this->webAssert = new WebAssert($this
    ->getSession());
}