You are here

public function AlterProductPurchasedEntityEventTest::testGetProduct in Commerce Google Tag Manager 8.2

Same name and namespace in other branches
  1. 8 tests/src/Kernel/AlterProductPurchasedEntityEventTest.php \Drupal\Tests\commerce_google_tag_manager\Kernel\AlterProductPurchasedEntityEventTest::testGetProduct()

@covers ::getProduct

File

tests/src/Kernel/AlterProductPurchasedEntityEventTest.php, line 84

Class

AlterProductPurchasedEntityEventTest
@coversDefaultClass \Drupal\commerce_google_tag_manager\Event\AlterProductPurchasedEntityEvent

Namespace

Drupal\Tests\commerce_google_tag_manager\Kernel

Code

public function testGetProduct() {
  $event = new AlterProductPurchasedEntityEvent($this->product, $this->orderItem, $this->purchasedEntity);
  $this
    ->assertInstanceOf(Product::class, $event
    ->getProduct());
}