function SimpleTestExampleTestCase::testSimpleTestExampleCreate
Same name in other branches
- 7.x-1.x simpletest_example/simpletest_example.test \SimpleTestExampleTestCase::testSimpleTestExampleCreate()
Create a simpletest_example node using the node form.
File
-
simpletest_example/
simpletest_example.test, line 45
Class
- SimpleTestExampleTestCase
- Tests the SimpleTest Example module's content type.
Code
public function testSimpleTestExampleCreate() {
// Create node to edit.
$edit = array();
$edit['title'] = $this->randomName(8);
$edit['body'] = $this->randomName(16);
$this->drupalPost('node/add/simpletest-example', $edit, t('Save'));
$this->assertText(t('simpletest_example page @title has been created.', array(
'@title' => $edit['title'],
)));
}