You are here

public function TaxTypeTest::testTaxType in Commerce Migrate 3.1.x

Same name in this branch
  1. 3.1.x modules/ubercart/tests/src/Kernel/Migrate/uc7/TaxTypeTest.php \Drupal\Tests\commerce_migrate_ubercart\Kernel\Migrate\uc7\TaxTypeTest::testTaxType()
  2. 3.1.x modules/ubercart/tests/src/Kernel/Migrate/uc6/TaxTypeTest.php \Drupal\Tests\commerce_migrate_ubercart\Kernel\Migrate\uc6\TaxTypeTest::testTaxType()
  3. 3.1.x modules/commerce/tests/src/Kernel/Migrate/commerce1/TaxTypeTest.php \Drupal\Tests\commerce_migrate_commerce\Kernel\Migrate\commerce1\TaxTypeTest::testTaxType()
Same name and namespace in other branches
  1. 8.2 modules/ubercart/tests/src/Kernel/Migrate/uc7/TaxTypeTest.php \Drupal\Tests\commerce_migrate_ubercart\Kernel\Migrate\uc7\TaxTypeTest::testTaxType()
  2. 3.0.x modules/ubercart/tests/src/Kernel/Migrate/uc7/TaxTypeTest.php \Drupal\Tests\commerce_migrate_ubercart\Kernel\Migrate\uc7\TaxTypeTest::testTaxType()

Test tax migration.

File

modules/ubercart/tests/src/Kernel/Migrate/uc7/TaxTypeTest.php, line 37

Class

TaxTypeTest
Tests tax type migration.

Namespace

Drupal\Tests\commerce_migrate_ubercart\Kernel\Migrate\uc7

Code

public function testTaxType() {
  $territory = [
    [
      'country_code' => 'CA',
    ],
  ];
  $this
    ->assertTaxType('station_maintenance', 'Station maintenance', 'custom', '0.05', $territory);
  $this
    ->assertTaxType('ca', 'CA', 'custom', '0.2', $territory);
  $this
    ->assertTaxType('us', 'US', 'custom', '0.4', $territory);
}