protected function BotchaBaseWebTestCase::createNodeWithCommentsEnabled in BOTCHA Spam Prevention 6.2
Same name and namespace in other branches
- 6 botcha.test \BotchaBaseWebTestCase::createNodeWithCommentsEnabled()
- 6.3 tests/botcha.simpletest.test \BotchaBaseWebTestCase::createNodeWithCommentsEnabled()
- 7 botcha.test \BotchaBaseWebTestCase::createNodeWithCommentsEnabled()
- 7.2 botcha.test \BotchaBaseWebTestCase::createNodeWithCommentsEnabled()
- 7.3 tests/botcha.simpletest.test \BotchaBaseWebTestCase::createNodeWithCommentsEnabled()
Helper function to create a node with comments enabled.
Return value
Created node object.
2 calls to BotchaBaseWebTestCase::createNodeWithCommentsEnabled()
- BotchaAdminTestCase::testBotchaAdminLinks in ./
botcha.test - Testing of the BOTCHA administration links.
- BotchaBaseWebTestCase::getForm in ./
botcha.test - Get one of predefined forms. Used to unify the process of testing.
File
- ./
botcha.test, line 125 - Tests for BOTCHA module.
Class
- BotchaBaseWebTestCase
- Base class for BOTCHA tests.
Code
protected function createNodeWithCommentsEnabled($type = 'page') {
$node_settings = array(
'type' => $type,
// @todo Abstract it.
//'comment' => COMMENT_NODE_OPEN,
'comment' => COMMENT_NODE_READ_WRITE,
);
$node = $this
->drupalCreateNode($node_settings);
return $node;
}