function BoxesTestPlugins::testBoxesTypeLinks in Boxes 7.2
Verity that the correct links appear
File
- ./
boxes.test, line 71 - Tests for block.module.
Class
- BoxesTestPlugins
- Test the API
Code
function testBoxesTypeLinks() {
$this
->drupalGet('block/add');
// Verify the block add pages exists
$this
->assertResponse(200, t('Block Add Page is accessible'));
// There should 2 plugins links
$this
->assertLinkByHref('block/add/test-box', 0, t('A link to the box add for each type should exist'));
$this
->assertLinkByHref('block/add/test-box-2', 0, t('A link to the box add for each type should exist'));
$this
->assertNoLinkByHref('block/add/test-no-boxes', t('A link to an invalid box type should not exist'));
$this
->assertNoLinkByHref('block/add/test-wrong-class', t('A link to an invalid box type should not exist'));
}