function BreakpointTest::testGetWeight

Same name and namespace in other branches
  1. 11.x core/modules/breakpoint/tests/src/Unit/BreakpointTest.php \Drupal\Tests\breakpoint\Unit\BreakpointTest::testGetWeight()
  2. 10 core/modules/breakpoint/tests/src/Unit/BreakpointTest.php \Drupal\Tests\breakpoint\Unit\BreakpointTest::testGetWeight()
  3. 9 core/modules/breakpoint/tests/src/Unit/BreakpointTest.php \Drupal\Tests\breakpoint\Unit\BreakpointTest::testGetWeight()
  4. 8.9.x core/modules/breakpoint/tests/src/Unit/BreakpointTest.php \Drupal\Tests\breakpoint\Unit\BreakpointTest::testGetWeight()

Tests get weight.

File

core/modules/breakpoint/tests/src/Unit/BreakpointTest.php, line 79

Class

BreakpointTest
Tests Drupal\breakpoint\Breakpoint.

Namespace

Drupal\Tests\breakpoint\Unit

Code

public function testGetWeight() : void {
  $this->pluginDefinition['weight'] = '4';
  $this->setupBreakpoint();
  // Assert that the type returned in an integer.
  $this->assertSame(4, $this->breakpoint
    ->getWeight());
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.