public function CommerceBaseTesterTestCase::testTestCreateDummyProductNodeBatch in Commerce Core 7
Test the createDummyProductNodeBatch function.
File
- tests/
commerce_base.test, line 888 - Defines abstract base test class for the Commerce module tests.
Class
- CommerceBaseTesterTestCase
- Test class to test the CommerceBaseTestCase functions. All testTestFoo functions have "testTest" in the name to indicate that they are verifying that a test is working. Somewhat "meta" to do this, but it eases test development.
Code
public function testTestCreateDummyProductNodeBatch() {
$product_nodes = $this
->createDummyProductNodeBatch(3);
$this
->drupalLogin($this->site_admin);
$product_node = $product_nodes[1];
$this
->drupalGet("node/{$product_node->nid}");
$this
->assertText($product_node->title, t('Product !product_title node page exists', array(
'product_title' => $product_node->title,
)));
}