You are here

public function TestOrderItemDiscountAdjustment::split in Commerce Migrate 3.1.x

Same name and namespace in other branches
  1. 8.2 modules/commerce/tests/src/Unit/Plugin/migrate/process/commerce1/OrderItemDiscountAdjustmentTest.php \Drupal\Tests\commerce_migrate_commerce\Unit\Plugin\migrate\process\commerce1\TestOrderItemDiscountAdjustment::split()
  2. 3.0.x modules/commerce/tests/src/Unit/Plugin/migrate/process/commerce1/OrderItemDiscountAdjustmentTest.php \Drupal\Tests\commerce_migrate_commerce\Unit\Plugin\migrate\process\commerce1\TestOrderItemDiscountAdjustment::split()

Calculates the adjustment amount for this line.

Parameters

int $num_product_line: The product line number.

bool $last_line: TRUE if this is the last line of the order to process FALSE otherwise.

\Drupal\commerce_price\Price $price: The price for this line.

Return value

\Drupal\commerce_price\Price|null The new price for this line item. NULL if no line number was provided.

Overrides OrderItemDiscountAdjustment::split

File

modules/commerce/tests/src/Unit/Plugin/migrate/process/commerce1/OrderItemDiscountAdjustmentTest.php, line 479

Class

TestOrderItemDiscountAdjustment
Test class for OrderItemDiscountAdjustment.

Namespace

Drupal\Tests\commerce_migrate_commerce\Unit\Plugin\migrate\process\commerce1

Code

public function split($num_product_line, $last_line, Price $price) {
  return parent::split($num_product_line, $last_line, $price);
}