You are here

protected function CommerceMigrateBaseTestCase::getProduct in Commerce Migrate 7

Load product by SKU.

Parameters

string $sku: Product SKU. See "products.csv".

Return value

\EntityDrupalWrapper Entity wrapper for commerce product.

See also

commerce_product_load_by_sku()

1 call to CommerceMigrateBaseTestCase::getProduct()
CommerceMigrateTestCase::testProduct in tests/commerce_migrate_tests.test
Tests integrity of a product.

File

tests/commerce_migrate_base.test, line 144
Base facade for "Commerce Migrate" tests.

Class

CommerceMigrateBaseTestCase
Class CommerceMigrateBaseTestCase.

Code

protected function getProduct($sku) {
  return $this
    ->getEntityWrapper('commerce_product', 'sku', $sku);
}