ShippingFlatRateTest.php in Commerce Migrate 3.0.x
Same filename in this branch
- 3.0.x modules/ubercart/tests/src/Kernel/Migrate/uc7/ShippingFlatRateTest.php
- 3.0.x modules/ubercart/tests/src/Kernel/Migrate/uc6/ShippingFlatRateTest.php
- 3.0.x modules/commerce/tests/src/Kernel/Migrate/commerce1/ShippingFlatRateTest.php
- 3.0.x modules/ubercart/tests/src/Kernel/Plugin/migrate/source/ShippingFlatRateTest.php
- 3.0.x modules/commerce/tests/src/Kernel/Plugin/migrate/source/commerce1/ShippingFlatRateTest.php
Same filename and directory in other branches
File
modules/ubercart/tests/src/Kernel/Migrate/uc7/ShippingFlatRateTest.phpView source
<?php
namespace Drupal\Tests\commerce_migrate_ubercart\Kernel\Migrate\uc7;
use Drupal\Tests\commerce_migrate\Kernel\CommerceMigrateTestTrait;
/**
* Tests flat rate shipping migration from Uberart 7.
*
* @requires module commerce_shipping
* @requires module physical
*
* @group commerce_migrate
* @group commerce_migrate_uc7
*/
class ShippingFlatRateTest extends Ubercart7TestBase {
use CommerceMigrateTestTrait;
/**
* {@inheritdoc}
*/
public static $modules = [
'commerce_order',
'commerce_price',
'commerce_product',
'commerce_shipping',
'commerce_store',
'path',
'path_alias',
'profile',
'physical',
'state_machine',
];
/**
* {@inheritdoc}
*/
protected function setUp() {
parent::setUp();
$this
->installEntitySchema('commerce_shipping_method');
$this
->executeMigration('uc_shipping_flat_rate');
}
/**
* Test flat rate shipping method migration.
*/
public function testShippingFlatRate() {
$type = [
'id' => '1',
'label' => 'Flat Rate',
'rate_amount' => [
'number' => '1.50000',
'currency_code' => 'USD',
],
'stores' => [
'1',
],
];
$this
->assertShippingMethod($type);
}
}
Classes
Name | Description |
---|---|
ShippingFlatRateTest | Tests flat rate shipping migration from Uberart 7. |