public function CommerceMigrateTestTrait::assertProfileType in Commerce Migrate 3.1.x
Same name and namespace in other branches
- 8.2 tests/src/Kernel/CommerceMigrateTestTrait.php \Drupal\Tests\commerce_migrate\Kernel\CommerceMigrateTestTrait::assertProfileType()
- 3.0.x tests/src/Kernel/CommerceMigrateTestTrait.php \Drupal\Tests\commerce_migrate\Kernel\CommerceMigrateTestTrait::assertProfileType()
Asserts a profile type configuration entity.
Parameters
string $id: The profile id.
string $label: The label for this profile.
bool $multiple: Set if this profile can have multiples.
bool $revisions: Set if this profile has revision.
3 calls to CommerceMigrateTestTrait::assertProfileType()
- ProfileTypeCustomerTest::testProfileType in modules/
ubercart/ tests/ src/ Kernel/ Migrate/ uc7/ ProfileTypeCustomerTest.php - Test profile migration.
- ProfileTypeCustomerTest::testProfileType in modules/
ubercart/ tests/ src/ Kernel/ Migrate/ uc6/ ProfileTypeCustomerTest.php - Test profile migration.
- ProfileTypeTest::testProfileType in modules/
commerce/ tests/ src/ Kernel/ Migrate/ commerce1/ ProfileTypeTest.php - Test profile type migration from Drupal 7 to 8.
File
- tests/
src/ Kernel/ CommerceMigrateTestTrait.php, line 696
Class
- CommerceMigrateTestTrait
- Helper function to test migrations.
Namespace
Drupal\Tests\commerce_migrate\KernelCode
public function assertProfileType($id, $label, $multiple, $revisions) {
$profile_type = ProfileType::load($id);
$this
->assertInstanceOf(ProfileType::class, $profile_type);
$this
->assertSame($label, $profile_type
->label());
$this
->assertSame($multiple, $profile_type
->allowsMultiple());
$this
->assertSame($revisions, $profile_type
->shouldCreateNewRevision());
}