protected function RenderElementTypesTest::assertNoTargetAction in Lingotek Translation 3.7.x
Same name and namespace in other branches
- 4.0.x tests/src/Functional/Render/Element/RenderElementTypesTest.php \Drupal\Tests\lingotek\Functional\Render\Element\RenderElementTypesTest::assertNoTargetAction()
- 3.6.x tests/src/Functional/Render/Element/RenderElementTypesTest.php \Drupal\Tests\lingotek\Functional\Render\Element\RenderElementTypesTest::assertNoTargetAction()
- 3.8.x tests/src/Functional/Render/Element/RenderElementTypesTest.php \Drupal\Tests\lingotek\Functional\Render\Element\RenderElementTypesTest::assertNoTargetAction()
2 calls to RenderElementTypesTest::assertNoTargetAction()
- RenderElementTypesTest::testLingotekTargetStatus in tests/
src/ Functional/ Render/ Element/ RenderElementTypesTest.php - Tests #type 'lingotek_source_status'.
- RenderElementTypesTest::testLingotekTargetStatuses in tests/
src/ Functional/ Render/ Element/ RenderElementTypesTest.php - Tests #type 'lingotek_source_statuses'.
File
- tests/
src/ Functional/ Render/ Element/ RenderElementTypesTest.php, line 389
Class
- RenderElementTypesTest
- Tests the markup of lingotek render element types passed to \Drupal::service('renderer')->render().
Namespace
Drupal\Tests\lingotek\Functional\Render\ElementCode
protected function assertNoTargetAction($text, $url) {
// Should be better with ul[@class="lingotek-target-actions"], but somehow doesn't work.
$link = $this
->xpath('//ul//li//a[@href="' . $url . '" and text()="' . $text . '"]');
$this
->assertCount(0, $link, 'Action exists.');
}