public function ApacheSolrRealTimeTest::TestArticleCommit in Apache Solr Real-Time 7
Create a new Article and check that it was committed to Solr.
File
- tests/
apachesolr_realtime.test, line 50 - Test cases for apachesolr_realtime module.
Class
- ApacheSolrRealTimeTest
- @file Test cases for apachesolr_realtime module.
Code
public function TestArticleCommit() {
// Define content for article.
$add_article = array(
'title' => $this
->randomName(8),
'body[und][0][value]' => $this
->randomName(56),
);
// Post article.
$this
->drupalPost('node/add/article', $add_article, t('Save'));
$this
->assertText("Article " . $add_article['title'] . " has been created", "Add Article message found.");
}