public function RouteWrapperTest::testIsContextualLink in Drupal 7 to 8/9 Module Upgrader 8
File
- tests/
src/ Unit/ Routing/ Drupal7/ RouteWrapperTest.php, line 108
Class
- RouteWrapperTest
- @group DMU.Routing
Namespace
Drupal\Tests\drupalmoduleupgrader\Unit\Routing\Drupal7Code
public function testIsContextualLink() {
$wrapper = $this
->getMockRouteWrapper();
$this
->assertFalse($wrapper
->isContextualLink());
$wrapper['type'] = 'MENU_LOCAL_ACTION';
$this
->assertTrue($wrapper
->isLocalAction());
$this
->assertFalse($wrapper
->isContextualLink());
$wrapper['context'] = 'MENU_CONTEXT_INLINE';
$this
->assertTrue($wrapper
->isContextualLink());
$wrapper['type'] = 'MENU_NORMAL_ITEM';
$this
->assertFalse($wrapper
->isContextualLink());
}