diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateAggregatorFeedTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateAggregatorFeedTest.php index b8b503e..457c7ae 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateAggregatorFeedTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateAggregatorFeedTest.php @@ -41,17 +41,17 @@ public function testAggregatorFeedImport() { /** @var Feed $feed */ $feed = Feed::load(5); $this->assertNotNull($feed->uuid()); - $this->assertEqual($feed->title->value, 'Know Your Meme'); - $this->assertEqual($feed->language()->getId(), 'en'); - $this->assertEqual($feed->url->value, 'http://knowyourmeme.com/newsfeed.rss'); + $this->assertIdentical($feed->title->value, 'Know Your Meme'); + $this->assertIdentical($feed->language()->getId(), 'en'); + $this->assertIdentical($feed->url->value, 'http://knowyourmeme.com/newsfeed.rss'); $this->assertEqual($feed->refresh->value, 900); $this->assertEqual($feed->checked->value, 1387659487); $this->assertEqual($feed->queued->value, 0); - $this->assertEqual($feed->link->value, 'http://knowyourmeme.com'); - $this->assertEqual($feed->description->value, 'New items added to the News Feed'); - $this->assertEqual($feed->image->value, 'http://b.thumbs.redditmedia.com/harEHsUUZVajabtC.png'); + $this->assertIdentical($feed->link->value, 'http://knowyourmeme.com'); + $this->assertIdentical($feed->description->value, 'New items added to the News Feed'); + $this->assertIdentical($feed->image->value, 'http://b.thumbs.redditmedia.com/harEHsUUZVajabtC.png'); $this->assertEqual($feed->hash->value, ''); - $this->assertEqual($feed->etag->value, '"213cc1365b96c310e92053c5551f0504"'); + $this->assertIdentical($feed->etag->value, '"213cc1365b96c310e92053c5551f0504"'); $this->assertEqual($feed->modified->value, 0); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateAggregatorItemTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateAggregatorItemTest.php index 93f1894..6b21ab5 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateAggregatorItemTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateAggregatorItemTest.php @@ -62,13 +62,13 @@ public function testAggregatorItem() { $item = Item::load(1); $this->assertEqual($item->id(), 1); $this->assertEqual($item->getFeedId(), 5); - $this->assertEqual($item->label(), 'This (three) weeks in Drupal Core - January 10th 2014'); - $this->assertEqual($item->getAuthor(), 'larowlan'); - $this->assertEqual($item->getDescription(), "

What's new with Drupal 8?

"); - $this->assertEqual($item->getLink(), 'https://groups.drupal.org/node/395218'); + $this->assertIdentical($item->label(), 'This (three) weeks in Drupal Core - January 10th 2014'); + $this->assertIdentical($item->getAuthor(), 'larowlan'); + $this->assertIdentical($item->getDescription(), "

What's new with Drupal 8?

"); + $this->assertIdentical($item->getLink(), 'https://groups.drupal.org/node/395218'); $this->assertEqual($item->getPostedTime(), 1389297196); - $this->assertEqual($item->language()->getId(), 'en'); - $this->assertEqual($item->getGuid(), '395218 at https://groups.drupal.org'); + $this->assertIdentical($item->language()->getId(), 'en'); + $this->assertIdentical($item->getGuid(), '395218 at https://groups.drupal.org'); } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateBlockContentTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateBlockContentTest.php index 8373030..bbd1132 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateBlockContentTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateBlockContentTest.php @@ -56,20 +56,20 @@ protected function setUp() { public function testBlockMigration() { /** @var BlockContent $block */ $block = entity_load('block_content', 1); - $this->assertEqual('My block 1', $block->label()); + $this->assertIdentical('My block 1', $block->label()); $this->assertEqual(1, $block->getRevisionId()); $this->assertTrue(REQUEST_TIME <= $block->getChangedTime() && $block->getChangedTime() <= time()); - $this->assertEqual('en', $block->language()->getId()); - $this->assertEqual('

My first custom block body

', $block->body->value); - $this->assertEqual('full_html', $block->body->format); + $this->assertIdentical('en', $block->language()->getId()); + $this->assertIdentical('

My first custom block body

', $block->body->value); + $this->assertIdentical('full_html', $block->body->format); $block = entity_load('block_content', 2); - $this->assertEqual('My block 2', $block->label()); + $this->assertIdentical('My block 2', $block->label()); $this->assertEqual(2, $block->getRevisionId()); $this->assertTrue(REQUEST_TIME <= $block->getChangedTime() && $block->getChangedTime() <= time()); - $this->assertEqual('en', $block->language()->getId()); - $this->assertEqual('

My second custom block body

', $block->body->value); - $this->assertEqual('full_html', $block->body->format); + $this->assertIdentical('en', $block->language()->getId()); + $this->assertIdentical('

My second custom block body

', $block->body->value); + $this->assertIdentical('full_html', $block->body->format); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateBlockTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateBlockTest.php index 48615f2..4fe41b7 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateBlockTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateBlockTest.php @@ -83,74 +83,74 @@ protected function setUp() { */ public function testBlockMigration() { $blocks = Block::loadMultiple(); - $this->assertEqual(count($blocks), 8); + $this->assertIdentical(count($blocks), 8); // User blocks $test_block_user = $blocks['user']; $this->assertNotNull($test_block_user); - $this->assertEqual('sidebar_first', $test_block_user->get('region')); - $this->assertEqual('bartik', $test_block_user->get('theme')); + $this->assertIdentical('sidebar_first', $test_block_user->get('region')); + $this->assertIdentical('bartik', $test_block_user->get('theme')); $visibility = $test_block_user->getVisibility(); $this->assertTrue(empty($visibility['request_path']['pages'])); - $this->assertEqual(0, $test_block_user->weight); + $this->assertIdentical(0, $test_block_user->weight); $test_block_user_1 = $blocks['user_1']; $this->assertNotNull($test_block_user_1); - $this->assertEqual('sidebar_first', $test_block_user_1->get('region')); - $this->assertEqual('bartik', $test_block_user_1->get('theme')); + $this->assertIdentical('sidebar_first', $test_block_user_1->get('region')); + $this->assertIdentical('bartik', $test_block_user_1->get('theme')); $visibility = $test_block_user_1->getVisibility(); $this->assertTrue(empty($visibility['request_path']['pages'])); - $this->assertEqual(0, $test_block_user_1->weight); + $this->assertIdentical(0, $test_block_user_1->weight); // Check system block $test_block_system = $blocks['system']; $this->assertNotNull($test_block_system); - $this->assertEqual('footer', $test_block_system->get('region')); - $this->assertEqual('bartik', $test_block_system->get('theme')); + $this->assertIdentical('footer', $test_block_system->get('region')); + $this->assertIdentical('bartik', $test_block_system->get('theme')); $visibility = $test_block_system->getVisibility(); $this->assertTrue(empty($visibility['request_path']['pages'])); - $this->assertEqual(-5, $test_block_system->weight); + $this->assertIdentical(-5, $test_block_system->weight); // Check menu blocks $test_block_menu = $blocks['menu']; $this->assertNotNull($test_block_menu); - $this->assertEqual('header', $test_block_menu->get('region')); - $this->assertEqual('bartik', $test_block_menu->get('theme')); + $this->assertIdentical('header', $test_block_menu->get('region')); + $this->assertIdentical('bartik', $test_block_menu->get('theme')); $visibility = $test_block_menu->getVisibility(); $this->assertTrue(empty($visibility['request_path']['pages'])); - $this->assertEqual(-5, $test_block_menu->weight); + $this->assertIdentical(-5, $test_block_menu->weight); // Check custom blocks $test_block_block = $blocks['block']; $this->assertNotNull($test_block_block); - $this->assertEqual('content', $test_block_block->get('region')); - $this->assertEqual('bartik', $test_block_block->get('theme')); + $this->assertIdentical('content', $test_block_block->get('region')); + $this->assertIdentical('bartik', $test_block_block->get('theme')); $visibility = $test_block_block->getVisibility(); - $this->assertEqual($visibility['request_path']['pages'], ''); - $this->assertEqual(0, $test_block_block->weight); + $this->assertIdentical($visibility['request_path']['pages'], ''); + $this->assertIdentical(0, $test_block_block->weight); $test_block_block_1 = $blocks['block_1']; $this->assertNotNull($test_block_block_1); - $this->assertEqual('right', $test_block_block_1->get('region')); - $this->assertEqual('bluemarine', $test_block_block_1->get('theme')); + $this->assertIdentical('right', $test_block_block_1->get('region')); + $this->assertIdentical('bluemarine', $test_block_block_1->get('theme')); $visibility = $test_block_block_1->getVisibility(); - $this->assertEqual($visibility['request_path']['pages'], 'node'); - $this->assertEqual(-4, $test_block_block_1->weight); + $this->assertIdentical($visibility['request_path']['pages'], 'node'); + $this->assertIdentical(-4, $test_block_block_1->weight); $test_block_block_2 = $blocks['block_2']; $this->assertNotNull($test_block_block_2); - $this->assertEqual('right', $test_block_block_2->get('region')); - $this->assertEqual('test_theme', $test_block_block_2->get('theme')); + $this->assertIdentical('right', $test_block_block_2->get('region')); + $this->assertIdentical('test_theme', $test_block_block_2->get('theme')); $visibility = $test_block_block_2->getVisibility(); $this->assertTrue(empty($visibility['request_path']['pages'])); - $this->assertEqual(-7, $test_block_block_2->weight); + $this->assertIdentical(-7, $test_block_block_2->weight); $test_block_block_3 = $blocks['block_3']; $this->assertNotNull($test_block_block_3); - $this->assertEqual('left', $test_block_block_3->get('region')); - $this->assertEqual('test_theme', $test_block_block_3->get('theme')); + $this->assertIdentical('left', $test_block_block_3->get('region')); + $this->assertIdentical('test_theme', $test_block_block_3->get('theme')); $visibility = $test_block_block_3->getVisibility(); $this->assertTrue(empty($visibility['request_path']['pages'])); - $this->assertEqual(-2, $test_block_block_3->weight); + $this->assertIdentical(-2, $test_block_block_3->weight); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateCckFieldValuesTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateCckFieldValuesTest.php index 9d21794..34c2897 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateCckFieldValuesTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateCckFieldValuesTest.php @@ -134,14 +134,14 @@ protected function setUp() { */ public function testCckFields() { $node = Node::load(1); - $this->assertEqual($node->field_test->value, 'This is a shared text field', "Shared field storage field is correct."); + $this->assertIdentical($node->field_test->value, 'This is a shared text field', "Shared field storage field is correct."); $this->assertEqual($node->field_test->format, 1, "Shared field storage field with multiple columns is correct."); $this->assertEqual($node->field_test_two->value, 10, 'Multi field storage field is correct'); $this->assertEqual($node->field_test_two[1]->value, 20, 'Multi field second value is correct.'); - $this->assertEqual($node->field_test_three->value, '42.42', 'Single field second value is correct.'); - $this->assertEqual($node->field_test_integer_selectlist[0]->value, '3412', 'Integer select list value is correct'); - $this->assertEqual($node->field_test_identical1->value, '1', 'Integer value is correct'); - $this->assertEqual($node->field_test_identical2->value, '1', 'Integer value is correct'); + $this->assertIdentical($node->field_test_three->value, '42.42', 'Single field second value is correct.'); + $this->assertIdentical($node->field_test_integer_selectlist[0]->value, '3412', 'Integer select list value is correct'); + $this->assertIdentical($node->field_test_identical1->value, '1', 'Integer value is correct'); + $this->assertIdentical($node->field_test_identical2->value, '1', 'Integer value is correct'); $planet_node = Node::load(3); $this->assertEqual($planet_node->field_multivalue->value, 33); diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentTest.php index 74ff074..7f730bb 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentTest.php @@ -71,21 +71,21 @@ protected function setUp() { public function testComments() { /** @var \Drupal\comment\CommentInterface $comment */ $comment = entity_load('comment', 1); - $this->assertEqual('The first comment.', $comment->getSubject()); - $this->assertEqual('The first comment body.', $comment->comment_body->value); - $this->assertEqual('filtered_html', $comment->comment_body->format); + $this->assertIdentical('The first comment.', $comment->getSubject()); + $this->assertIdentical('The first comment body.', $comment->comment_body->value); + $this->assertIdentical('filtered_html', $comment->comment_body->format); $this->assertEqual(0, $comment->pid->target_id); $this->assertEqual(1, $comment->getCommentedEntityId()); - $this->assertEqual('node', $comment->getCommentedEntityTypeId()); - $this->assertEqual('en', $comment->language()->getId()); - $this->assertEqual('comment_no_subject', $comment->getTypeId()); + $this->assertIdentical('node', $comment->getCommentedEntityTypeId()); + $this->assertIdentical('en', $comment->language()->getId()); + $this->assertIdentical('comment_no_subject', $comment->getTypeId()); $comment = entity_load('comment', 2); - $this->assertEqual('The response to the second comment.', $comment->subject->value); + $this->assertIdentical('The response to the second comment.', $comment->subject->value); $this->assertEqual(3, $comment->pid->target_id); $comment = entity_load('comment', 3); - $this->assertEqual('The second comment.', $comment->subject->value); + $this->assertIdentical('The second comment.', $comment->subject->value); $this->assertEqual(0, $comment->pid->target_id); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentTypeTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentTypeTest.php index cc25e4e..ce02d67 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentTypeTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentTypeTest.php @@ -41,9 +41,9 @@ protected function setUp() { */ public function testCommentType() { $comment_type = entity_load('comment_type', 'comment'); - $this->assertEqual('node', $comment_type->getTargetEntityTypeId()); + $this->assertIdentical('node', $comment_type->getTargetEntityTypeId()); $comment_type = entity_load('comment_type', 'comment_no_subject'); - $this->assertEqual('node', $comment_type->getTargetEntityTypeId()); + $this->assertIdentical('node', $comment_type->getTargetEntityTypeId()); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentVariableEntityDisplayTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentVariableEntityDisplayTest.php index c0f058e..54638ae 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentVariableEntityDisplayTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentVariableEntityDisplayTest.php @@ -30,9 +30,9 @@ class MigrateCommentVariableEntityDisplayTest extends MigrateCommentVariableDisp public function testCommentEntityDisplay() { foreach ($this->types as $type) { $component = entity_get_display('node', $type, 'default')->getComponent('comment'); - $this->assertEqual($component['label'], 'hidden'); - $this->assertEqual($component['type'], 'comment_default'); - $this->assertEqual($component['weight'], 20); + $this->assertIdentical($component['label'], 'hidden'); + $this->assertIdentical($component['type'], 'comment_default'); + $this->assertIdentical($component['weight'], 20); } } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentVariableEntityFormDisplaySubjectTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentVariableEntityFormDisplaySubjectTest.php index 67539b6..67c5503 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentVariableEntityFormDisplaySubjectTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentVariableEntityFormDisplaySubjectTest.php @@ -59,8 +59,8 @@ protected function setUp() { public function testCommentEntityFormDisplay() { $component = entity_get_form_display('comment', 'comment', 'default') ->getComponent('subject'); - $this->assertEqual($component['type'], 'string_textfield'); - $this->assertEqual($component['weight'], 10); + $this->assertIdentical($component['type'], 'string_textfield'); + $this->assertIdentical($component['weight'], 10); $component = entity_get_form_display('comment', 'comment_no_subject', 'default') ->getComponent('subject'); $this->assertNull($component); diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentVariableEntityFormDisplayTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentVariableEntityFormDisplayTest.php index f0b3dc5..427b375 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentVariableEntityFormDisplayTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentVariableEntityFormDisplayTest.php @@ -25,8 +25,8 @@ class MigrateCommentVariableEntityFormDisplayTest extends MigrateCommentVariable public function testCommentEntityFormDisplay() { foreach ($this->types as $type) { $component = entity_get_form_display('node', $type, 'default')->getComponent('comment'); - $this->assertEqual($component['type'], 'comment_default'); - $this->assertEqual($component['weight'], 20); + $this->assertIdentical($component['type'], 'comment_default'); + $this->assertIdentical($component['weight'], 20); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentVariableInstanceTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentVariableInstanceTest.php index c6e369a..609c108 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentVariableInstanceTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateCommentVariableInstanceTest.php @@ -65,24 +65,24 @@ protected function setUp() { */ public function testCommentFieldInstance() { $node = entity_create('node', array('type' => 'page')); - $this->assertEqual($node->comment->status, 0); - $this->assertEqual($node->comment->getFieldDefinition()->getName(), 'comment'); + $this->assertIdentical($node->comment->status, 0); + $this->assertIdentical($node->comment->getFieldDefinition()->getName(), 'comment'); $settings = $node->comment->getFieldDefinition()->getSettings(); - $this->assertEqual($settings['default_mode'], 4); - $this->assertEqual($settings['per_page'], 50); - $this->assertEqual($settings['anonymous'], 0); + $this->assertIdentical($settings['default_mode'], 4); + $this->assertIdentical($settings['per_page'], 50); + $this->assertIdentical($settings['anonymous'], 0); $this->assertEqual($settings['form_location'], 0); - $this->assertEqual($settings['preview'], 1); + $this->assertIdentical($settings['preview'], 1); $node = entity_create('node', array('type' => 'story')); - $this->assertEqual($node->comment_no_subject->status, 2); - $this->assertEqual($node->comment_no_subject->getFieldDefinition()->getName(), 'comment_no_subject'); + $this->assertIdentical($node->comment_no_subject->status, 2); + $this->assertIdentical($node->comment_no_subject->getFieldDefinition()->getName(), 'comment_no_subject'); $settings = $node->comment_no_subject->getFieldDefinition()->getSettings(); - $this->assertEqual($settings['default_mode'], 2); - $this->assertEqual($settings['per_page'], 70); - $this->assertEqual($settings['anonymous'], 1); + $this->assertIdentical($settings['default_mode'], 2); + $this->assertIdentical($settings['per_page'], 70); + $this->assertIdentical($settings['anonymous'], 1); $this->assertEqual($settings['form_location'], 0); - $this->assertEqual($settings['preview'], 0); + $this->assertIdentical($settings['preview'], 0); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateContactCategoryTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateContactCategoryTest.php index c055144..3ca6202 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateContactCategoryTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateContactCategoryTest.php @@ -46,22 +46,22 @@ protected function setUp() { public function testContactCategory() { /** @var \Drupal\contact\Entity\ContactForm $contact_form */ $contact_form = ContactForm::load('website_feedback'); - $this->assertEqual($contact_form->label(), 'Website feedback'); - $this->assertEqual($contact_form->getRecipients(), array('admin@example.com')); - $this->assertEqual($contact_form->getReply(), ''); - $this->assertEqual($contact_form->getWeight(), 0); + $this->assertIdentical($contact_form->label(), 'Website feedback'); + $this->assertIdentical($contact_form->getRecipients(), array('admin@example.com')); + $this->assertIdentical($contact_form->getReply(), ''); + $this->assertIdentical($contact_form->getWeight(), 0); $contact_form = ContactForm::load('some_other_category'); - $this->assertEqual($contact_form->label(), 'Some other category'); - $this->assertEqual($contact_form->getRecipients(), array('test@example.com')); - $this->assertEqual($contact_form->getReply(), 'Thanks for contacting us, we will reply ASAP!'); - $this->assertEqual($contact_form->getWeight(), 1); + $this->assertIdentical($contact_form->label(), 'Some other category'); + $this->assertIdentical($contact_form->getRecipients(), array('test@example.com')); + $this->assertIdentical($contact_form->getReply(), 'Thanks for contacting us, we will reply ASAP!'); + $this->assertIdentical($contact_form->getWeight(), 1); $contact_form = ContactForm::load('a_category_much_longer_than_thir'); - $this->assertEqual($contact_form->label(), 'A category much longer than thirty two characters'); - $this->assertEqual($contact_form->getRecipients(), array('fortyninechars@example.com')); - $this->assertEqual($contact_form->getReply(), ''); - $this->assertEqual($contact_form->getWeight(), 2); + $this->assertIdentical($contact_form->label(), 'A category much longer than thirty two characters'); + $this->assertIdentical($contact_form->getRecipients(), array('fortyninechars@example.com')); + $this->assertIdentical($contact_form->getReply(), ''); + $this->assertIdentical($contact_form->getWeight(), 2); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateDateFormatTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateDateFormatTest.php index 247f00f..ad15c4e 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateDateFormatTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateDateFormatTest.php @@ -35,13 +35,13 @@ protected function setUp() { */ public function testDateFormats() { $short_date_format = entity_load('date_format', 'short'); - $this->assertEqual('\S\H\O\R\T m/d/Y - H:i', $short_date_format->getPattern()); + $this->assertIdentical('\S\H\O\R\T m/d/Y - H:i', $short_date_format->getPattern()); $medium_date_format = entity_load('date_format', 'medium'); - $this->assertEqual('\M\E\D\I\U\M D, m/d/Y - H:i', $medium_date_format->getPattern()); + $this->assertIdentical('\M\E\D\I\U\M D, m/d/Y - H:i', $medium_date_format->getPattern()); $long_date_format = entity_load('date_format', 'long'); - $this->assertEqual('\L\O\N\G l, F j, Y - H:i', $long_date_format->getPattern()); + $this->assertIdentical('\L\O\N\G l, F j, Y - H:i', $long_date_format->getPattern()); // Test that we can re-import using the EntityDateFormat destination. Database::getConnection('default', 'migrate') @@ -55,7 +55,7 @@ public function testDateFormats() { $executable->import(); $short_date_format = entity_load('date_format', 'short'); - $this->assertEqual('\S\H\O\R\T d/m/Y - H:i', $short_date_format->getPattern()); + $this->assertIdentical('\S\H\O\R\T d/m/Y - H:i', $short_date_format->getPattern()); } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateFieldFormatterSettingsTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateFieldFormatterSettingsTest.php index 305d3b8..07f11e3 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateFieldFormatterSettingsTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateFieldFormatterSettingsTest.php @@ -220,7 +220,7 @@ public function testEntityDisplaySettings() { $component = $display->getComponent('field_test_datetime'); $this->assertEqual($component, $expected); // Test that our Id map has the correct data. - $this->assertEqual(array('node', 'story', 'teaser', 'field_test'), entity_load('migration', 'd6_field_formatter_settings')->getIdMap()->lookupDestinationID(array('story', 'teaser', 'node', 'field_test'))); + $this->assertIdentical(array('node', 'story', 'teaser', 'field_test'), entity_load('migration', 'd6_field_formatter_settings')->getIdMap()->lookupDestinationID(array('story', 'teaser', 'node', 'field_test'))); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateFieldInstanceTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateFieldInstanceTest.php index 31f206d..1fa5629 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateFieldInstanceTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateFieldInstanceTest.php @@ -85,14 +85,14 @@ public function testFieldInstanceSettings() { $entity = entity_create('node', array('type' => 'story')); // Test a text field. $field = FieldConfig::load('node.story.field_test'); - $this->assertEqual($field->label(), 'Text Field'); + $this->assertIdentical($field->label(), 'Text Field'); $expected = array('max_length' => 255); - $this->assertEqual($field->getSettings(), $expected); - $this->assertEqual('text for default value', $entity->field_test->value); + $this->assertIdentical($field->getSettings(), $expected); + $this->assertIdentical('text for default value', $entity->field_test->value); // Test a number field. $field = FieldConfig::load('node.story.field_test_two'); - $this->assertEqual($field->label(), 'Integer Field'); + $this->assertIdentical($field->label(), 'Integer Field'); $expected = array( 'min' => '10', 'max' => '100', @@ -104,7 +104,7 @@ public function testFieldInstanceSettings() { $this->assertEqual($field->getSettings(), $expected); $field = FieldConfig::load('node.story.field_test_four'); - $this->assertEqual($field->label(), 'Float Field'); + $this->assertIdentical($field->label(), 'Float Field'); $expected = array( 'min' => 100, 'max' => 200, @@ -115,12 +115,12 @@ public function testFieldInstanceSettings() { // Test email field. $field = FieldConfig::load('node.story.field_test_email'); - $this->assertEqual($field->label(), 'Email Field'); - $this->assertEqual('benjy@example.com', $entity->field_test_email->value, 'Field field_test_email default_value is correct.'); + $this->assertIdentical($field->label(), 'Email Field'); + $this->assertIdentical('benjy@example.com', $entity->field_test_email->value, 'Field field_test_email default_value is correct.'); // Test a filefield. $field = FieldConfig::load('node.story.field_test_filefield'); - $this->assertEqual($field->label(), 'File Field'); + $this->assertIdentical($field->label(), 'File Field'); $expected = array( 'file_extensions' => 'txt pdf doc', 'file_directory' => 'images', @@ -139,11 +139,11 @@ public function testFieldInstanceSettings() { // Test a link field. $field = FieldConfig::load('node.story.field_test_link'); - $this->assertEqual($field->label(), 'Link Field'); + $this->assertIdentical($field->label(), 'Link Field'); $expected = array('title' => 2, 'link_type' => LinkItemInterface::LINK_GENERIC); - $this->assertEqual($field->getSettings(), $expected); - $this->assertEqual('default link title', $entity->field_test_link->title, 'Field field_test_link default title is correct.'); - $this->assertEqual('http://drupal.org', $entity->field_test_link->url, 'Field field_test_link default title is correct.'); + $this->assertIdentical($field->getSettings(), $expected); + $this->assertIdentical('default link title', $entity->field_test_link->title, 'Field field_test_link default title is correct.'); + $this->assertIdentical('http://drupal.org', $entity->field_test_link->url, 'Field field_test_link default title is correct.'); } /** diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateFieldTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateFieldTest.php index 2f1c179..24ad19f 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateFieldTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateFieldTest.php @@ -47,70 +47,70 @@ public function testFields() { /** @var \Drupal\field\Entity\FieldStorageConfig $field_storage */ $field_storage = entity_load('field_storage_config', 'node.field_test'); $expected = array('max_length' => 255); - $this->assertEqual($field_storage->type, "text", t('Field type is @fieldtype. It should be text.', array('@fieldtype' => $field_storage->type))); - $this->assertEqual($field_storage->status(), TRUE, "Status is TRUE"); - $this->assertEqual($field_storage->settings, $expected, "Field type text settings are correct"); + $this->assertIdentical($field_storage->type, "text", t('Field type is @fieldtype. It should be text.', array('@fieldtype' => $field_storage->type))); + $this->assertIdentical($field_storage->status(), TRUE, "Status is TRUE"); + $this->assertIdentical($field_storage->settings, $expected, "Field type text settings are correct"); // Integer field. $field_storage = entity_load('field_storage_config', 'node.field_test_two'); - $this->assertEqual($field_storage->type, "integer", t('Field type is @fieldtype. It should be integer.', array('@fieldtype' => $field_storage->type))); + $this->assertIdentical($field_storage->type, "integer", t('Field type is @fieldtype. It should be integer.', array('@fieldtype' => $field_storage->type))); // Float field. $field_storage = entity_load('field_storage_config', 'node.field_test_three'); - $this->assertEqual($field_storage->type, "decimal", t('Field type is @fieldtype. It should be decimal.', array('@fieldtype' => $field_storage->type))); + $this->assertIdentical($field_storage->type, "decimal", t('Field type is @fieldtype. It should be decimal.', array('@fieldtype' => $field_storage->type))); // Link field. $field_storage = entity_load('field_storage_config', 'node.field_test_link'); - $this->assertEqual($field_storage->type, "link", t('Field type is @fieldtype. It should be link.', array('@fieldtype' => $field_storage->type))); + $this->assertIdentical($field_storage->type, "link", t('Field type is @fieldtype. It should be link.', array('@fieldtype' => $field_storage->type))); // File field. $field_storage = entity_load('field_storage_config', 'node.field_test_filefield'); - $this->assertEqual($field_storage->type, "file", t('Field type is @fieldtype. It should be file.', array('@fieldtype' => $field_storage->type))); + $this->assertIdentical($field_storage->type, "file", t('Field type is @fieldtype. It should be file.', array('@fieldtype' => $field_storage->type))); $field_storage = entity_load('field_storage_config', 'node.field_test_imagefield'); - $this->assertEqual($field_storage->type, "image", t('Field type is @fieldtype. It should be image.', array('@fieldtype' => $field_storage->type))); + $this->assertIdentical($field_storage->type, "image", t('Field type is @fieldtype. It should be image.', array('@fieldtype' => $field_storage->type))); $settings = $field_storage->getSettings(); - $this->assertEqual($settings['target_type'], 'file'); - $this->assertEqual($settings['uri_scheme'], 'public'); + $this->assertIdentical($settings['target_type'], 'file'); + $this->assertIdentical($settings['uri_scheme'], 'public'); $this->assertEqual($settings['default_image']['fid'], ''); - $this->assertEqual(array_filter($settings['default_image']), array()); + $this->assertIdentical(array_filter($settings['default_image']), array()); // Phone field. $field_storage = entity_load('field_storage_config', 'node.field_test_phone'); - $this->assertEqual($field_storage->type, "telephone", t('Field type is @fieldtype. It should be telephone.', array('@fieldtype' => $field_storage->type))); + $this->assertIdentical($field_storage->type, "telephone", t('Field type is @fieldtype. It should be telephone.', array('@fieldtype' => $field_storage->type))); // Date field. $field_storage = entity_load('field_storage_config', 'node.field_test_datetime'); - $this->assertEqual($field_storage->type, "datetime", t('Field type is @fieldtype. It should be datetime.', array('@fieldtype' => $field_storage->type))); - $this->assertEqual($field_storage->status(), FALSE, "Status is FALSE"); + $this->assertIdentical($field_storage->type, "datetime", t('Field type is @fieldtype. It should be datetime.', array('@fieldtype' => $field_storage->type))); + $this->assertIdentical($field_storage->status(), FALSE, "Status is FALSE"); // Decimal field with radio buttons. $field_storage = entity_load('field_storage_config', 'node.field_test_decimal_radio_buttons'); - $this->assertEqual($field_storage->type, "list_float", t('Field type is @fieldtype. It should be list_float.', array('@fieldtype' => $field_storage->type))); + $this->assertIdentical($field_storage->type, "list_float", t('Field type is @fieldtype. It should be list_float.', array('@fieldtype' => $field_storage->type))); $this->assertNotNull($field_storage->settings['allowed_values']['1.2'], t('First allowed value key is set to 1.2')); $this->assertNotNull($field_storage->settings['allowed_values']['2.1'], t('Second allowed value key is set to 2.1')); - $this->assertEqual($field_storage->settings['allowed_values']['1.2'], '1.2', t('First allowed value is set to 1.2')); - $this->assertEqual($field_storage->settings['allowed_values']['2.1'], '2.1', t('Second allowed value is set to 1.2')); + $this->assertIdentical($field_storage->settings['allowed_values']['1.2'], '1.2', t('First allowed value is set to 1.2')); + $this->assertIdentical($field_storage->settings['allowed_values']['2.1'], '2.1', t('Second allowed value is set to 1.2')); // Float field with a single checkbox. $field_storage = entity_load('field_storage_config', 'node.field_test_float_single_checkbox'); - $this->assertEqual($field_storage->type, "boolean", t('Field type is @fieldtype. It should be boolean.', array('@fieldtype' => $field_storage->type))); + $this->assertIdentical($field_storage->type, "boolean", t('Field type is @fieldtype. It should be boolean.', array('@fieldtype' => $field_storage->type))); // Integer field with a select list. $field_storage = entity_load('field_storage_config', 'node.field_test_integer_selectlist'); - $this->assertEqual($field_storage->type, "list_integer", t('Field type is @fieldtype. It should be list_integer.', array('@fieldtype' => $field_storage->type))); + $this->assertIdentical($field_storage->type, "list_integer", t('Field type is @fieldtype. It should be list_integer.', array('@fieldtype' => $field_storage->type))); $this->assertNotNull($field_storage->settings['allowed_values']['1234'], t('First allowed value key is set to 1234')); $this->assertNotNull($field_storage->settings['allowed_values']['2341'], t('Second allowed value key is set to 2341')); $this->assertNotNull($field_storage->settings['allowed_values']['3412'], t('Third allowed value key is set to 3412')); $this->assertNotNull($field_storage->settings['allowed_values']['4123'], t('Fourth allowed value key is set to 4123')); - $this->assertEqual($field_storage->settings['allowed_values']['1234'], '1234', t('First allowed value is set to 1234')); - $this->assertEqual($field_storage->settings['allowed_values']['2341'], '2341', t('Second allowed value is set to 2341')); - $this->assertEqual($field_storage->settings['allowed_values']['3412'], '3412', t('Third allowed value is set to 3412')); - $this->assertEqual($field_storage->settings['allowed_values']['4123'], '4123', t('Fourth allowed value is set to 4123')); + $this->assertIdentical($field_storage->settings['allowed_values']['1234'], '1234', t('First allowed value is set to 1234')); + $this->assertIdentical($field_storage->settings['allowed_values']['2341'], '2341', t('Second allowed value is set to 2341')); + $this->assertIdentical($field_storage->settings['allowed_values']['3412'], '3412', t('Third allowed value is set to 3412')); + $this->assertIdentical($field_storage->settings['allowed_values']['4123'], '4123', t('Fourth allowed value is set to 4123')); // Text field with a single checkbox. $field_storage = entity_load('field_storage_config', 'node.field_test_text_single_checkbox'); - $this->assertEqual($field_storage->type, "boolean", t('Field type is @fieldtype. It should be boolean.', array('@fieldtype' => $field_storage->type))); + $this->assertIdentical($field_storage->type, "boolean", t('Field type is @fieldtype. It should be boolean.', array('@fieldtype' => $field_storage->type))); } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateFieldWidgetSettingsTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateFieldWidgetSettingsTest.php index 09b922c..5a0fb26 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateFieldWidgetSettingsTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateFieldWidgetSettingsTest.php @@ -77,37 +77,37 @@ protected function setUp() { public function testWidgetSettings() { // Test the config can be loaded. $form_display = entity_load('entity_form_display', 'node.story.default'); - $this->assertEqual(is_null($form_display), FALSE, "Form display node.story.default loaded with config."); + $this->assertIdentical(is_null($form_display), FALSE, "Form display node.story.default loaded with config."); // Text field. $component = $form_display->getComponent('field_test'); $expected = array('weight' => 1, 'type' => 'text_textfield'); $expected['settings'] = array('size' => 60, 'placeholder' => ''); $expected['third_party_settings'] = array(); - $this->assertEqual($component, $expected, 'Text field settings are correct.'); + $this->assertIdentical($component, $expected, 'Text field settings are correct.'); // Integer field. $component = $form_display->getComponent('field_test_two'); $expected['type'] = 'number'; $expected['weight'] = 2; $expected['settings'] = array('placeholder' => ''); - $this->assertEqual($component, $expected, 'Integer field settings are correct.'); + $this->assertIdentical($component, $expected, 'Integer field settings are correct.'); // Float field. $component = $form_display->getComponent('field_test_three'); $expected['weight'] = 3; - $this->assertEqual($component, $expected, 'Float field settings are correct.'); + $this->assertIdentical($component, $expected, 'Float field settings are correct.'); // Email field. $component = $form_display->getComponent('field_test_email'); $expected['type'] = 'email_default'; $expected['weight'] = 4; - $this->assertEqual($component, $expected, 'Email field settings are correct.'); + $this->assertIdentical($component, $expected, 'Email field settings are correct.'); // Link field. $component = $form_display->getComponent('field_test_link'); - $this->assertEqual($component['type'], 'link_default'); - $this->assertEqual($component['weight'], 5); + $this->assertIdentical($component['type'], 'link_default'); + $this->assertIdentical($component['weight'], 5); $this->assertFalse(array_filter($component['settings'])); // File field. @@ -115,36 +115,36 @@ public function testWidgetSettings() { $expected['type'] = 'file_generic'; $expected['weight'] = 7; $expected['settings'] = array('progress_indicator' => 'bar'); - $this->assertEqual($component, $expected, 'File field settings are correct.'); + $this->assertIdentical($component, $expected, 'File field settings are correct.'); // Image field. $component = $form_display->getComponent('field_test_imagefield'); $expected['type'] = 'image_image'; $expected['weight'] = 8; $expected['settings'] = array('progress_indicator' => 'bar', 'preview_image_style' => 'thumbnail'); - $this->assertEqual($component, $expected, 'Image field settings are correct.'); + $this->assertIdentical($component, $expected, 'Image field settings are correct.'); // Phone field. $component = $form_display->getComponent('field_test_phone'); $expected['type'] = 'telephone_default'; $expected['weight'] = 9; $expected['settings'] = array('placeholder' => ''); - $this->assertEqual($component, $expected, 'Phone field settings are correct.'); + $this->assertIdentical($component, $expected, 'Phone field settings are correct.'); // Date fields. $component = $form_display->getComponent('field_test_date'); $expected['type'] = 'datetime_default'; $expected['weight'] = 10; $expected['settings'] = array(); - $this->assertEqual($component, $expected, 'Date field settings are correct.'); + $this->assertIdentical($component, $expected, 'Date field settings are correct.'); $component = $form_display->getComponent('field_test_datestamp'); $expected['weight'] = 11; - $this->assertEqual($component, $expected, 'Date stamp field settings are correct.'); + $this->assertIdentical($component, $expected, 'Date stamp field settings are correct.'); $component = $form_display->getComponent('field_test_datetime'); $expected['weight'] = 12; - $this->assertEqual($component, $expected, 'Datetime field settings are correct.'); + $this->assertIdentical($component, $expected, 'Datetime field settings are correct.'); } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateFileTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateFileTest.php index 48645c1..6c1443d 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateFileTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateFileTest.php @@ -47,10 +47,10 @@ protected function setUp() { public function testFiles() { /** @var \Drupal\file\FileInterface $file */ $file = entity_load('file', 1); - $this->assertEqual($file->getFilename(), 'Image1.png'); + $this->assertIdentical($file->getFilename(), 'Image1.png'); $this->assertEqual($file->getSize(), 39325); - $this->assertEqual($file->getFileUri(), 'public://image-1.png'); - $this->assertEqual($file->getMimeType(), 'image/png'); + $this->assertIdentical($file->getFileUri(), 'public://image-1.png'); + $this->assertIdentical($file->getMimeType(), 'image/png'); // It is pointless to run the second half from MigrateDrupal6Test. if (empty($this->standalone)) { return; @@ -67,7 +67,7 @@ public function testFiles() { $executable->import(); $file = entity_load('file', 2); - $this->assertEqual($file->getFileUri(), 'public://core/modules/simpletest/files/image-2.jpg'); + $this->assertIdentical($file->getFileUri(), 'public://core/modules/simpletest/files/image-2.jpg'); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateMenuTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateMenuTest.php index a786eca..824a178 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateMenuTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateMenuTest.php @@ -39,9 +39,9 @@ protected function setUp() { */ public function testMenu() { $navigation_menu = Menu::load('navigation'); - $this->assertEqual($navigation_menu->id(), 'navigation'); - $this->assertEqual($navigation_menu->label(), 'Navigation'); - $this->assertEqual($navigation_menu->getDescription() , 'The navigation menu is provided by Drupal and is the main interactive menu for any site. It is usually the only menu that contains personalized links for authenticated users, and is often not even visible to anonymous users.'); + $this->assertIdentical($navigation_menu->id(), 'navigation'); + $this->assertIdentical($navigation_menu->label(), 'Navigation'); + $this->assertIdentical($navigation_menu->getDescription() , 'The navigation menu is provided by Drupal and is the main interactive menu for any site. It is usually the only menu that contains personalized links for authenticated users, and is often not even visible to anonymous users.'); // Test that we can re-import using the ConfigEntityBase destination. Database::getConnection('default', 'migrate') @@ -56,7 +56,7 @@ public function testMenu() { $executable->import(); $navigation_menu = entity_load_unchanged('menu', 'navigation'); - $this->assertEqual($navigation_menu->label(), 'Home Navigation'); + $this->assertIdentical($navigation_menu->label(), 'Home Navigation'); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateNodeRevisionTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateNodeRevisionTest.php index 21d3006..17cfd26 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateNodeRevisionTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateNodeRevisionTest.php @@ -53,20 +53,20 @@ public function testNodeRevision() { /** @var \Drupal\node\NodeInterface $node */ $this->assertEqual($node->id(), 1); $this->assertEqual($node->getRevisionId(), 2); - $this->assertEqual($node->langcode->value, 'und'); - $this->assertEqual($node->getTitle(), 'Test title rev 2'); - $this->assertEqual($node->body->value, 'body test rev 2'); - $this->assertEqual($node->body->summary, 'teaser test rev 2'); + $this->assertIdentical($node->langcode->value, 'und'); + $this->assertIdentical($node->getTitle(), 'Test title rev 2'); + $this->assertIdentical($node->body->value, 'body test rev 2'); + $this->assertIdentical($node->body->summary, 'teaser test rev 2'); $this->assertEqual($node->getRevisionAuthor()->id(), 2); - $this->assertEqual($node->revision_log->value, 'modified rev 2'); - $this->assertEqual($node->getRevisionCreationTime(), '1390095702'); + $this->assertIdentical($node->revision_log->value, 'modified rev 2'); + $this->assertIdentical($node->getRevisionCreationTime(), '1390095702'); $node = \Drupal::entityManager()->getStorage('node')->loadRevision(5); $this->assertEqual($node->id(), 1); - $this->assertEqual($node->body->value, 'body test rev 3'); + $this->assertIdentical($node->body->value, 'body test rev 3'); $this->assertEqual($node->getRevisionAuthor()->id(), 1); - $this->assertEqual($node->revision_log->value, 'modified rev 3'); - $this->assertEqual($node->getRevisionCreationTime(), '1390095703'); + $this->assertIdentical($node->revision_log->value, 'modified rev 3'); + $this->assertIdentical($node->getRevisionCreationTime(), '1390095703'); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateNodeTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateNodeTest.php index e3bed3a..20f998a 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateNodeTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateNodeTest.php @@ -39,20 +39,20 @@ protected function setUp() { public function testNode() { $node = Node::load(1); $this->assertEqual($node->id(), 1, 'Node 1 loaded.'); - $this->assertEqual($node->langcode->value, 'und'); - $this->assertEqual($node->body->value, 'test'); - $this->assertEqual($node->body->summary, 'test'); - $this->assertEqual($node->body->format, 'filtered_html'); - $this->assertEqual($node->getType(), 'story', 'Node has the correct bundle.'); - $this->assertEqual($node->getTitle(), 'Test title', 'Node has the correct title.'); + $this->assertIdentical($node->langcode->value, 'und'); + $this->assertIdentical($node->body->value, 'test'); + $this->assertIdentical($node->body->summary, 'test'); + $this->assertIdentical($node->body->format, 'filtered_html'); + $this->assertIdentical($node->getType(), 'story', 'Node has the correct bundle.'); + $this->assertIdentical($node->getTitle(), 'Test title', 'Node has the correct title.'); $this->assertEqual($node->getCreatedTime(), 1388271197, 'Node has the correct created time.'); - $this->assertEqual($node->isSticky(), FALSE); + $this->assertIdentical($node->isSticky(), FALSE); $this->assertEqual($node->getOwnerId(), 1); $this->assertEqual($node->getRevisionCreationTime(), 1390095701, 'Node has the correct revision timestamp.'); /** @var \Drupal\node\NodeInterface $node_revision */ $node_revision = \Drupal::entityManager()->getStorage('node')->loadRevision(1); - $this->assertEqual($node_revision->getTitle(), 'Test title'); + $this->assertIdentical($node_revision->getTitle(), 'Test title'); $this->assertEqual($node_revision->getRevisionAuthor()->id(), 1, 'Node revision has the correct user'); // This is empty on the first revision. $this->assertEqual($node_revision->revision_log->value, ''); @@ -81,10 +81,10 @@ public function testNode() { $executable->import(); $node = Node::load(1); - $this->assertEqual($node->getTitle(), 'New node title'); + $this->assertIdentical($node->getTitle(), 'New node title'); // Test a multi-column fields are correctly upgraded. - $this->assertEqual($node->body->value, 'test'); - $this->assertEqual($node->body->format, 'full_html'); + $this->assertIdentical($node->body->value, 'test'); + $this->assertIdentical($node->body->format, 'full_html'); $node = Node::load(3); // Test that format = 0 from source maps to filtered_html. diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateNodeTypeTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateNodeTypeTest.php index 034dd04..defb0af 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateNodeTypeTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateNodeTypeTest.php @@ -46,42 +46,42 @@ public function testNodeType() { $migration = entity_load('migration', 'd6_node_type'); // Test the test_page content type. $node_type_page = entity_load('node_type', 'test_page'); - $this->assertEqual($node_type_page->id(), 'test_page', 'Node type test_page loaded'); + $this->assertIdentical($node_type_page->id(), 'test_page', 'Node type test_page loaded'); - $this->assertEqual($node_type_page->displaySubmitted(), TRUE); - $this->assertEqual($node_type_page->isNewRevision(), FALSE); - $this->assertEqual($node_type_page->getPreviewMode(), DRUPAL_OPTIONAL); - $this->assertEqual(array('test_page'), $migration->getIdMap()->lookupDestinationID(array('test_page'))); + $this->assertIdentical($node_type_page->displaySubmitted(), TRUE); + $this->assertIdentical($node_type_page->isNewRevision(), FALSE); + $this->assertIdentical($node_type_page->getPreviewMode(), DRUPAL_OPTIONAL); + $this->assertIdentical(array('test_page'), $migration->getIdMap()->lookupDestinationID(array('test_page'))); // Test we have a body field. $field = FieldConfig::loadByName('node', 'test_page', 'body'); - $this->assertEqual($field->getLabel(), 'This is the body field label', 'Body field was found.'); + $this->assertIdentical($field->getLabel(), 'This is the body field label', 'Body field was found.'); // Test the test_story content type. $node_type_story = entity_load('node_type', 'test_story'); - $this->assertEqual($node_type_story->id(), 'test_story', 'Node type test_story loaded'); + $this->assertIdentical($node_type_story->id(), 'test_story', 'Node type test_story loaded'); - $this->assertEqual($node_type_story->displaySubmitted(), TRUE); - $this->assertEqual($node_type_story->isNewRevision(), FALSE); - $this->assertEqual($node_type_story->getPreviewMode(), DRUPAL_OPTIONAL); - $this->assertEqual(array('test_story'), $migration->getIdMap()->lookupDestinationID(array('test_story'))); + $this->assertIdentical($node_type_story->displaySubmitted(), TRUE); + $this->assertIdentical($node_type_story->isNewRevision(), FALSE); + $this->assertIdentical($node_type_story->getPreviewMode(), DRUPAL_OPTIONAL); + $this->assertIdentical(array('test_story'), $migration->getIdMap()->lookupDestinationID(array('test_story'))); // Test we don't have a body field. $field = FieldConfig::loadByName('node', 'test_story', 'body'); - $this->assertEqual($field, NULL, 'No body field found'); + $this->assertIdentical($field, NULL, 'No body field found'); // Test the test_event content type. $node_type_event = entity_load('node_type', 'test_event'); - $this->assertEqual($node_type_event->id(), 'test_event', 'Node type test_event loaded'); + $this->assertIdentical($node_type_event->id(), 'test_event', 'Node type test_event loaded'); - $this->assertEqual($node_type_event->displaySubmitted(), TRUE); - $this->assertEqual($node_type_event->isNewRevision(), TRUE); - $this->assertEqual($node_type_event->getPreviewMode(), DRUPAL_OPTIONAL); - $this->assertEqual(array('test_event'), $migration->getIdMap()->lookupDestinationID(array('test_event'))); + $this->assertIdentical($node_type_event->displaySubmitted(), TRUE); + $this->assertIdentical($node_type_event->isNewRevision(), TRUE); + $this->assertIdentical($node_type_event->getPreviewMode(), DRUPAL_OPTIONAL); + $this->assertIdentical(array('test_event'), $migration->getIdMap()->lookupDestinationID(array('test_event'))); // Test we have a body field. $field = FieldConfig::loadByName('node', 'test_event', 'body'); - $this->assertEqual($field->getLabel(), 'Body', 'Body field was found.'); + $this->assertIdentical($field->getLabel(), 'Body', 'Body field was found.'); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateSearchPageTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateSearchPageTest.php index 31e4c36..bec2f8a 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateSearchPageTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateSearchPageTest.php @@ -47,15 +47,15 @@ public function testSearchPage() { $id = 'node_search'; /** @var \Drupal\search\Entity\SearchPage $search_page */ $search_page = entity_load('search_page', $id); - $this->assertEqual($search_page->id(), $id); + $this->assertIdentical($search_page->id(), $id); $configuration = $search_page->getPlugin()->getConfiguration(); - $this->assertEqual($configuration['rankings'], array( + $this->assertIdentical($configuration['rankings'], array( 'comments' => 5, 'relevance' => 2, 'sticky' => 8, 'views' => 1, )); - $this->assertEqual($search_page->getPath(), 'node'); + $this->assertIdentical($search_page->getPath(), 'node'); // Test that we can re-import using the EntitySearchPage destination. Database::getConnection('default', 'migrate') @@ -70,7 +70,7 @@ public function testSearchPage() { $search_page = entity_load('search_page', $id); $configuration = $search_page->getPlugin()->getConfiguration(); - $this->assertEqual($configuration['rankings']['comments'], 4); + $this->assertIdentical($configuration['rankings']['comments'], 4); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateTaxonomyTermTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateTaxonomyTermTest.php index d2eb969..9dff86e 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateTaxonomyTermTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateTaxonomyTermTest.php @@ -90,7 +90,7 @@ public function testTaxonomyTerms() { $term = $terms[$tid]; $this->assertIdentical($term->name->value, "term {$tid} of vocabulary {$values['source_vid']}"); $this->assertIdentical($term->description->value, "description of term {$tid} of vocabulary {$values['source_vid']}"); - $this->assertEqual($term->vid->target_id, $values['vid']); + $this->assertIdentical($term->vid->target_id, $values['vid']); $this->assertEqual($term->weight->value, $values['weight']); if ($values['parent'] === array(0)) { $this->assertEqual($term->parent->target_id, 0); diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateTaxonomyVocabularyTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateTaxonomyVocabularyTest.php index 607d4d7..aa23003 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateTaxonomyVocabularyTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateTaxonomyVocabularyTest.php @@ -45,17 +45,17 @@ public function testTaxonomyVocabulary() { for ($i = 0; $i < 3; $i++) { $j = $i + 1; $vocabulary = entity_load('taxonomy_vocabulary', "vocabulary_{$j}_i_{$i}_"); - $this->assertEqual(array($vocabulary->id()), entity_load('migration', 'd6_taxonomy_vocabulary')->getIdMap()->lookupDestinationID(array($j))); - $this->assertEqual($vocabulary->name, "vocabulary $j (i=$i)"); - $this->assertEqual($vocabulary->description, "description of vocabulary $j (i=$i)"); - $this->assertEqual($vocabulary->hierarchy, $i); - $this->assertEqual($vocabulary->weight, 4 + $i); + $this->assertIdentical(array($vocabulary->id()), entity_load('migration', 'd6_taxonomy_vocabulary')->getIdMap()->lookupDestinationID(array($j))); + $this->assertIdentical($vocabulary->name, "vocabulary $j (i=$i)"); + $this->assertIdentical($vocabulary->description, "description of vocabulary $j (i=$i)"); + $this->assertIdentical($vocabulary->hierarchy, $i); + $this->assertIdentical($vocabulary->weight, 4 + $i); } $vocabulary = entity_load('taxonomy_vocabulary', 'vocabulary_name_much_longer_than'); - $this->assertEqual($vocabulary->name, 'vocabulary name much longer than thirty two characters'); - $this->assertEqual($vocabulary->description, 'description of vocabulary name much longer than thirty two characters'); - $this->assertEqual($vocabulary->hierarchy, 3); - $this->assertEqual($vocabulary->weight, 7); + $this->assertIdentical($vocabulary->name, 'vocabulary name much longer than thirty two characters'); + $this->assertIdentical($vocabulary->description, 'description of vocabulary name much longer than thirty two characters'); + $this->assertIdentical($vocabulary->hierarchy, 3); + $this->assertIdentical($vocabulary->weight, 7); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateTermNodeRevisionTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateTermNodeRevisionTest.php index 6992929..d7042e7 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateTermNodeRevisionTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateTermNodeRevisionTest.php @@ -43,7 +43,7 @@ protected function setUp() { */ public function testTermRevisionNode() { $node = \Drupal::entityManager()->getStorage('node')->loadRevision(2); - $this->assertEqual(count($node->vocabulary_3_i_2_), 2); + $this->assertIdentical(count($node->vocabulary_3_i_2_), 2); $this->assertEqual($node->vocabulary_3_i_2_[0]->target_id, 4); $this->assertEqual($node->vocabulary_3_i_2_[1]->target_id, 5); } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateTermNodeTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateTermNodeTest.php index cd51592..d88b4f1 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateTermNodeTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateTermNodeTest.php @@ -38,10 +38,10 @@ public function testTermNode() { $node_storage->resetCache(array(1, 2)); $nodes = Node::loadMultiple(array(1, 2)); $node = $nodes[1]; - $this->assertEqual(count($node->vocabulary_1_i_0_), 1); + $this->assertIdentical(count($node->vocabulary_1_i_0_), 1); $this->assertEqual($node->vocabulary_1_i_0_[0]->target_id, 1); $node = $nodes[2]; - $this->assertEqual(count($node->vocabulary_2_i_1_), 2); + $this->assertIdentical(count($node->vocabulary_2_i_1_), 2); $this->assertEqual($node->vocabulary_2_i_1_[0]->target_id, 2); $this->assertEqual($node->vocabulary_2_i_1_[1]->target_id, 3); } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadEntityDisplayTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadEntityDisplayTest.php index b967b0a..3a1be63 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadEntityDisplayTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadEntityDisplayTest.php @@ -56,18 +56,18 @@ protected function setUp() { public function testUploadEntityDisplay() { $display = entity_get_display('node', 'page', 'default'); $component = $display->getComponent('upload'); - $this->assertEqual($component['type'], 'file_default'); + $this->assertIdentical($component['type'], 'file_default'); $display = entity_get_display('node', 'story', 'default'); $component = $display->getComponent('upload'); - $this->assertEqual($component['type'], 'file_default'); + $this->assertIdentical($component['type'], 'file_default'); // Assure this doesn't exist. $display = entity_get_display('node', 'article', 'default'); $component = $display->getComponent('upload'); $this->assertTrue(is_null($component)); - $this->assertEqual(array('node', 'page', 'default', 'upload'), entity_load('migration', 'd6_upload_entity_display')->getIdMap()->lookupDestinationID(array('page'))); + $this->assertIdentical(array('node', 'page', 'default', 'upload'), entity_load('migration', 'd6_upload_entity_display')->getIdMap()->lookupDestinationID(array('page'))); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadEntityFormDisplayTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadEntityFormDisplayTest.php index c3f6309..2aed10d 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadEntityFormDisplayTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadEntityFormDisplayTest.php @@ -57,18 +57,18 @@ protected function setUp() { public function testUploadEntityFormDisplay() { $display = entity_get_form_display('node', 'page', 'default'); $component = $display->getComponent('upload'); - $this->assertEqual($component['type'], 'file_generic'); + $this->assertIdentical($component['type'], 'file_generic'); $display = entity_get_form_display('node', 'story', 'default'); $component = $display->getComponent('upload'); - $this->assertEqual($component['type'], 'file_generic'); + $this->assertIdentical($component['type'], 'file_generic'); // Assure this doesn't exist. $display = entity_get_form_display('node', 'article', 'default'); $component = $display->getComponent('upload'); $this->assertTrue(is_null($component)); - $this->assertEqual(array('node', 'page', 'default', 'upload'), entity_load('migration', 'd6_upload_entity_form_display')->getIdMap()->lookupDestinationID(array('page'))); + $this->assertIdentical(array('node', 'page', 'default', 'upload'), entity_load('migration', 'd6_upload_entity_form_display')->getIdMap()->lookupDestinationID(array('page'))); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadFieldTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadFieldTest.php index 617f9e9..f0667c1 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadFieldTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadFieldTest.php @@ -43,8 +43,8 @@ protected function setUp() { */ public function testUpload() { $field_storage = entity_load('field_storage_config', 'node.upload'); - $this->assertEqual($field_storage->id(), 'node.upload'); - $this->assertEqual(array('node', 'upload'), entity_load('migration', 'd6_upload_field')->getIdMap()->lookupDestinationID(array(''))); + $this->assertIdentical($field_storage->id(), 'node.upload'); + $this->assertIdentical(array('node', 'upload'), entity_load('migration', 'd6_upload_field')->getIdMap()->lookupDestinationID(array(''))); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadInstanceTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadInstanceTest.php index b44a378..9b026ee 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadInstanceTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadInstanceTest.php @@ -67,19 +67,19 @@ protected function setUp() { public function testUploadFieldInstance() { $field = FieldConfig::load('node.page.upload'); $settings = $field->getSettings(); - $this->assertEqual($field->id(), 'node.page.upload'); - $this->assertEqual($settings['file_extensions'], 'jpg jpeg gif png txt doc xls pdf ppt pps odt ods odp'); - $this->assertEqual($settings['max_filesize'], '1MB'); - $this->assertEqual($settings['description_field'], TRUE); + $this->assertIdentical($field->id(), 'node.page.upload'); + $this->assertIdentical($settings['file_extensions'], 'jpg jpeg gif png txt doc xls pdf ppt pps odt ods odp'); + $this->assertIdentical($settings['max_filesize'], '1MB'); + $this->assertIdentical($settings['description_field'], TRUE); $field = FieldConfig::load('node.story.upload'); - $this->assertEqual($field->id(), 'node.story.upload'); + $this->assertIdentical($field->id(), 'node.story.upload'); // Shouldn't exist. $field = FieldConfig::load('node.article.upload'); $this->assertTrue(is_null($field)); - $this->assertEqual(array('node', 'page', 'upload'), entity_load('migration', 'd6_upload_field_instance')->getIdMap()->lookupDestinationID(array('page'))); + $this->assertIdentical(array('node', 'page', 'upload'), entity_load('migration', 'd6_upload_field_instance')->getIdMap()->lookupDestinationID(array('page'))); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadTest.php index ca1ee62..f24caa9 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateUploadTest.php @@ -36,19 +36,19 @@ function testUpload() { $node_storage->resetCache(array(1, 2)); $nodes = Node::loadMultiple(array(1, 2)); $node = $nodes[1]; - $this->assertEqual(count($node->upload), 1); + $this->assertIdentical(count($node->upload), 1); $this->assertEqual($node->upload[0]->target_id, 1); - $this->assertEqual($node->upload[0]->description, 'file 1-1-1'); - $this->assertEqual($node->upload[0]->isDisplayed(), FALSE); + $this->assertIdentical($node->upload[0]->description, 'file 1-1-1'); + $this->assertIdentical($node->upload[0]->isDisplayed(), FALSE); $node = $nodes[2]; - $this->assertEqual(count($node->upload), 2); + $this->assertIdentical(count($node->upload), 2); $this->assertEqual($node->upload[0]->target_id, 3); - $this->assertEqual($node->upload[0]->description, 'file 2-3-3'); - $this->assertEqual($node->upload[0]->isDisplayed(), FALSE); + $this->assertIdentical($node->upload[0]->description, 'file 2-3-3'); + $this->assertIdentical($node->upload[0]->isDisplayed(), FALSE); $this->assertEqual($node->upload[1]->target_id, 2); - $this->assertEqual($node->upload[1]->isDisplayed(), TRUE); - $this->assertEqual($node->upload[1]->description, 'file 2-3-2'); + $this->assertIdentical($node->upload[1]->isDisplayed(), TRUE); + $this->assertIdentical($node->upload[1]->description, 'file 2-3-2'); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureEntityDisplayTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureEntityDisplayTest.php index 040c906..ef718d8 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureEntityDisplayTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureEntityDisplayTest.php @@ -48,10 +48,10 @@ protected function setUp() { public function testUserPictureEntityDisplay() { $display = entity_get_display('user', 'user', 'default'); $component = $display->getComponent('user_picture'); - $this->assertEqual($component['type'], 'image'); - $this->assertEqual($component['settings']['image_link'], 'content'); + $this->assertIdentical($component['type'], 'image'); + $this->assertIdentical($component['settings']['image_link'], 'content'); - $this->assertEqual(array('user', 'user', 'default', 'user_picture'), entity_load('migration', 'd6_user_picture_entity_display')->getIdMap()->lookupDestinationID(array(''))); + $this->assertIdentical(array('user', 'user', 'default', 'user_picture'), entity_load('migration', 'd6_user_picture_entity_display')->getIdMap()->lookupDestinationID(array(''))); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureEntityFormDisplayTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureEntityFormDisplayTest.php index 3a1b06a..d272bba 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureEntityFormDisplayTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureEntityFormDisplayTest.php @@ -47,10 +47,10 @@ protected function setUp() { public function testUserPictureEntityFormDisplay() { $display = entity_get_form_display('user', 'user', 'default'); $component = $display->getComponent('user_picture'); - $this->assertEqual($component['type'], 'image_image'); - $this->assertEqual($component['settings']['progress_indicator'], 'throbber'); + $this->assertIdentical($component['type'], 'image_image'); + $this->assertIdentical($component['settings']['progress_indicator'], 'throbber'); - $this->assertEqual(array('user', 'user', 'default', 'user_picture'), entity_load('migration', 'd6_user_picture_entity_form_display')->getIdMap()->lookupDestinationID(array(''))); + $this->assertIdentical(array('user', 'user', 'default', 'user_picture'), entity_load('migration', 'd6_user_picture_entity_form_display')->getIdMap()->lookupDestinationID(array(''))); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureFieldTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureFieldTest.php index 5fd7b30..11f3f84 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureFieldTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureFieldTest.php @@ -34,8 +34,8 @@ protected function setUp() { */ public function testUserPictureField() { $field_storage = entity_load('field_storage_config', 'user.user_picture'); - $this->assertEqual($field_storage->id(), 'user.user_picture'); - $this->assertEqual(array('user', 'user_picture'), entity_load('migration', 'd6_user_picture_field')->getIdMap()->lookupDestinationID(array(''))); + $this->assertIdentical($field_storage->id(), 'user.user_picture'); + $this->assertIdentical(array('user', 'user_picture'), entity_load('migration', 'd6_user_picture_field')->getIdMap()->lookupDestinationID(array(''))); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureFileTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureFileTest.php index ff204f7..10b2c29 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureFileTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureFileTest.php @@ -51,14 +51,14 @@ public function testUserPictures() { $files = entity_load_multiple('file', $file_ids); /** @var \Drupal\file\FileInterface $file */ $file = array_shift($files); - $this->assertEqual($file->getFilename(), 'image-test.jpg'); - $this->assertEqual($file->getFileUri(), 'public://image-test.jpg'); + $this->assertIdentical($file->getFilename(), 'image-test.jpg'); + $this->assertIdentical($file->getFileUri(), 'public://image-test.jpg'); $this->assertEqual($file->getSize(), 1901); - $this->assertEqual($file->getMimeType(), 'image/jpeg'); + $this->assertIdentical($file->getMimeType(), 'image/jpeg'); $file = array_shift($files); - $this->assertEqual($file->getFilename(), 'image-test.png'); - $this->assertEqual($file->getFileUri(), 'public://image-test.png'); + $this->assertIdentical($file->getFilename(), 'image-test.png'); + $this->assertIdentical($file->getFileUri(), 'public://image-test.png'); $this->assertFalse($files); } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureInstanceTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureInstanceTest.php index edd676a..08015a3 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureInstanceTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserPictureInstanceTest.php @@ -55,12 +55,12 @@ protected function setUp() { public function testUserPictureFieldInstance() { $field = FieldConfig::load('user.user.user_picture'); $settings = $field->getSettings(); - $this->assertEqual($settings['file_extensions'], 'png gif jpg jpeg'); - $this->assertEqual($settings['file_directory'], 'pictures'); - $this->assertEqual($settings['max_filesize'], '30KB'); - $this->assertEqual($settings['max_resolution'], '85x85'); + $this->assertIdentical($settings['file_extensions'], 'png gif jpg jpeg'); + $this->assertIdentical($settings['file_directory'], 'pictures'); + $this->assertIdentical($settings['max_filesize'], '30KB'); + $this->assertIdentical($settings['max_resolution'], '85x85'); - $this->assertEqual(array('user', 'user', 'user_picture'), entity_load('migration', 'd6_user_picture_field_instance')->getIdMap()->lookupDestinationID(array(''))); + $this->assertIdentical(array('user', 'user', 'user_picture'), entity_load('migration', 'd6_user_picture_field_instance')->getIdMap()->lookupDestinationID(array(''))); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileEntityDisplayTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileEntityDisplayTest.php index aded50f..889ea80 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileEntityDisplayTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileEntityDisplayTest.php @@ -103,15 +103,15 @@ public function testUserProfileFields() { // Test a text field. $component = $display->getComponent('profile_color'); - $this->assertEqual($component['type'], 'text_default'); + $this->assertIdentical($component['type'], 'text_default'); // Test a list field. $component = $display->getComponent('profile_bands'); - $this->assertEqual($component['type'], 'text_default'); + $this->assertIdentical($component['type'], 'text_default'); // Test a date field. $component = $display->getComponent('profile_birthdate'); - $this->assertEqual($component['type'], 'datetime_default'); + $this->assertIdentical($component['type'], 'datetime_default'); // Test PROFILE_PRIVATE field is hidden. $this->assertNull($display->getComponent('profile_sell_address')); diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileEntityFormDisplayTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileEntityFormDisplayTest.php index 627c8d9..74de4f6 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileEntityFormDisplayTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileEntityFormDisplayTest.php @@ -98,15 +98,15 @@ public function testUserProfileEntityFormDisplay() { // Test a text field. $component = $display->getComponent('profile_color'); - $this->assertEqual($component['type'], 'text_textfield'); + $this->assertIdentical($component['type'], 'text_textfield'); // Test a list field. $component = $display->getComponent('profile_bands'); - $this->assertEqual($component['type'], 'text_textfield'); + $this->assertIdentical($component['type'], 'text_textfield'); // Test a date field. $component = $display->getComponent('profile_birthdate'); - $this->assertEqual($component['type'], 'datetime_default'); + $this->assertIdentical($component['type'], 'datetime_default'); // Test PROFILE_PRIVATE field is hidden. $this->assertNull($display->getComponent('profile_sell_address')); @@ -116,8 +116,8 @@ public function testUserProfileEntityFormDisplay() { // Test that a checkbox field has the proper display label setting. $component = $display->getComponent('profile_love_migrations'); - $this->assertEqual($component['type'], 'boolean_checkbox'); - $this->assertEqual($component['settings']['display_label'], true); + $this->assertIdentical($component['type'], 'boolean_checkbox'); + $this->assertIdentical($component['settings']['display_label'], true); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileFieldInstanceTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileFieldInstanceTest.php index b76bb11..d888d5b 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileFieldInstanceTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileFieldInstanceTest.php @@ -51,45 +51,45 @@ protected function setUp() { public function testUserProfileFields() { // Migrated a text field. $field = FieldConfig::load('user.user.profile_color'); - $this->assertEqual($field->label(), 'Favorite color'); - $this->assertEqual($field->getDescription(), 'List your favorite color'); + $this->assertIdentical($field->label(), 'Favorite color'); + $this->assertIdentical($field->getDescription(), 'List your favorite color'); // Migrated a textarea. $field = FieldConfig::load('user.user.profile_biography'); - $this->assertEqual($field->label(), 'Biography'); - $this->assertEqual($field->getDescription(), 'Tell people a little bit about yourself'); + $this->assertIdentical($field->label(), 'Biography'); + $this->assertIdentical($field->getDescription(), 'Tell people a little bit about yourself'); // Migrated checkbox field. $field = FieldConfig::load('user.user.profile_sell_address'); - $this->assertEqual($field->label(), 'Sell your email address?'); - $this->assertEqual($field->getDescription(), "If you check this box, we'll sell your address to spammers to help line the pockets of our shareholders. Thanks!"); + $this->assertIdentical($field->label(), 'Sell your email address?'); + $this->assertIdentical($field->getDescription(), "If you check this box, we'll sell your address to spammers to help line the pockets of our shareholders. Thanks!"); // Migrated selection field. $field = FieldConfig::load('user.user.profile_sold_to'); - $this->assertEqual($field->label(), 'Sales Category'); - $this->assertEqual($field->getDescription(), "Select the sales categories to which this user's address was sold."); + $this->assertIdentical($field->label(), 'Sales Category'); + $this->assertIdentical($field->getDescription(), "Select the sales categories to which this user's address was sold."); // Migrated list field. $field = FieldConfig::load('user.user.profile_bands'); - $this->assertEqual($field->label(), 'Favorite bands'); - $this->assertEqual($field->getDescription(), "Enter your favorite bands. When you've saved your profile, you'll be able to find other people with the same favorites."); + $this->assertIdentical($field->label(), 'Favorite bands'); + $this->assertIdentical($field->getDescription(), "Enter your favorite bands. When you've saved your profile, you'll be able to find other people with the same favorites."); /* // Migrated URL field. $field = FieldConfig::load('user.user.profile_blog'); - $this->assertEqual($field->label(), 'Your blog'); - $this->assertEqual($field->getDescription(), "Paste the full URL, including http://, of your personal blog."); + $this->assertIdentical($field->label(), 'Your blog'); + $this->assertIdentical($field->getDescription(), "Paste the full URL, including http://, of your personal blog."); */ // Migrated date field. $field = FieldConfig::load('user.user.profile_birthdate'); - $this->assertEqual($field->label(), 'Birthdate'); - $this->assertEqual($field->getDescription(), "Enter your birth date and we'll send you a coupon."); + $this->assertIdentical($field->label(), 'Birthdate'); + $this->assertIdentical($field->getDescription(), "Enter your birth date and we'll send you a coupon."); // Another migrated checkbox field, with a different source visibility setting. $field = FieldConfig::load('user.user.profile_love_migrations'); - $this->assertEqual($field->label(), 'I love migrations'); - $this->assertEqual($field->getDescription(), "If you check this box, you love migrations."); + $this->assertIdentical($field->label(), 'I love migrations'); + $this->assertIdentical($field->getDescription(), "If you check this box, you love migrations."); } /** diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileFieldTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileFieldTest.php index 735e045..392ae6c 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileFieldTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileFieldTest.php @@ -40,22 +40,22 @@ protected function setUp() { public function testUserProfileFields() { // Migrated a text field. $field_storage = entity_load('field_storage_config', 'user.profile_color'); - $this->assertEqual($field_storage->type, 'text', 'Field type is text.'); - $this->assertEqual($field_storage->cardinality, 1, 'Text field has correct cardinality'); + $this->assertIdentical($field_storage->type, 'text', 'Field type is text.'); + $this->assertIdentical($field_storage->cardinality, 1, 'Text field has correct cardinality'); // Migrated a textarea. $field_storage = entity_load('field_storage_config', 'user.profile_biography'); - $this->assertEqual($field_storage->type, 'text_long', 'Field type is text_long.'); + $this->assertIdentical($field_storage->type, 'text_long', 'Field type is text_long.'); // Migrated checkbox field. $field_storage = entity_load('field_storage_config', 'user.profile_sell_address'); - $this->assertEqual($field_storage->type, 'boolean', 'Field type is boolean.'); + $this->assertIdentical($field_storage->type, 'boolean', 'Field type is boolean.'); // Migrated selection field. $field_storage = entity_load('field_storage_config', 'user.profile_sold_to'); - $this->assertEqual($field_storage->type, 'list_string', 'Field type is list_string.'); + $this->assertIdentical($field_storage->type, 'list_string', 'Field type is list_string.'); $settings = $field_storage->getSettings(); - $this->assertEqual($settings['allowed_values'], array( + $this->assertIdentical($settings['allowed_values'], array( 'Pill spammers' => 'Pill spammers', 'Fitness spammers' => 'Fitness spammers', 'Back\slash' => 'Back\slash', @@ -64,23 +64,23 @@ public function testUserProfileFields() { 'Faithful servant' => 'Faithful servant', 'Anonymous donor' => 'Anonymous donor', )); - $this->assertEqual($field_storage->type, 'list_string', 'Field type is list_string.'); + $this->assertIdentical($field_storage->type, 'list_string', 'Field type is list_string.'); // Migrated list field. $field_storage = entity_load('field_storage_config', 'user.profile_bands'); - $this->assertEqual($field_storage->type, 'text', 'Field type is text.'); - $this->assertEqual($field_storage->cardinality, -1, 'List field has correct cardinality'); + $this->assertIdentical($field_storage->type, 'text', 'Field type is text.'); + $this->assertIdentical($field_storage->cardinality, -1, 'List field has correct cardinality'); /* // Migrated URL field. $field_storage = entity_load('field_storage_config', 'user.profile_blog'); - $this->assertEqual($field_storage->type, 'link', 'Field type is link.'); + $this->assertIdentical($field_storage->type, 'link', 'Field type is link.'); */ // Migrated date field. $field_storage = entity_load('field_storage_config', 'user.profile_birthdate'); - $this->assertEqual($field_storage->type, 'datetime', 'Field type is datetime.'); - $this->assertEqual($field_storage->settings['datetime_type'], 'date'); + $this->assertIdentical($field_storage->type, 'datetime', 'Field type is datetime.'); + $this->assertIdentical($field_storage->settings['datetime_type'], 'date'); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileValuesTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileValuesTest.php index 1e6b586..c474769 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileValuesTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserProfileValuesTest.php @@ -144,24 +144,24 @@ protected function setUp() { public function testUserProfileValues() { $user = User::load(2); $this->assertFalse(is_null($user)); - $this->assertEqual($user->profile_color->value, 'red'); - $this->assertEqual($user->profile_biography->value, 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam nulla sapien, congue nec risus ut, adipiscing aliquet felis. Maecenas quis justo vel nulla varius euismod. Quisque metus metus, cursus sit amet sem non, bibendum vehicula elit. Cras dui nisl, eleifend at iaculis vitae, lacinia ut felis. Nullam aliquam ligula volutpat nulla consectetur accumsan. Maecenas tincidunt molestie diam, a accumsan enim fringilla sit amet. Morbi a tincidunt tellus. Donec imperdiet scelerisque porta. Sed quis sem bibendum eros congue sodales. Vivamus vel fermentum est, at rutrum orci. Nunc consectetur purus ut dolor pulvinar, ut volutpat felis congue. Cras tincidunt odio sed neque sollicitudin, vehicula tempor metus scelerisque.'); - $this->assertEqual($user->profile_sell_address->value, '1'); - $this->assertEqual($user->profile_sold_to->value, 'Back\slash'); - $this->assertEqual($user->profile_bands[0]->value, 'AC/DC'); - $this->assertEqual($user->profile_bands[1]->value, 'Eagles'); - $this->assertEqual($user->profile_bands[2]->value, 'Elton John'); - $this->assertEqual($user->profile_bands[3]->value, 'Lemonheads'); - $this->assertEqual($user->profile_bands[4]->value, 'Rolling Stones'); - $this->assertEqual($user->profile_bands[5]->value, 'Queen'); - $this->assertEqual($user->profile_bands[6]->value, 'The White Stripes'); - $this->assertEqual($user->profile_birthdate->value, '1974-06-02'); + $this->assertIdentical($user->profile_color->value, 'red'); + $this->assertIdentical($user->profile_biography->value, 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam nulla sapien, congue nec risus ut, adipiscing aliquet felis. Maecenas quis justo vel nulla varius euismod. Quisque metus metus, cursus sit amet sem non, bibendum vehicula elit. Cras dui nisl, eleifend at iaculis vitae, lacinia ut felis. Nullam aliquam ligula volutpat nulla consectetur accumsan. Maecenas tincidunt molestie diam, a accumsan enim fringilla sit amet. Morbi a tincidunt tellus. Donec imperdiet scelerisque porta. Sed quis sem bibendum eros congue sodales. Vivamus vel fermentum est, at rutrum orci. Nunc consectetur purus ut dolor pulvinar, ut volutpat felis congue. Cras tincidunt odio sed neque sollicitudin, vehicula tempor metus scelerisque.'); + $this->assertIdentical($user->profile_sell_address->value, '1'); + $this->assertIdentical($user->profile_sold_to->value, 'Back\slash'); + $this->assertIdentical($user->profile_bands[0]->value, 'AC/DC'); + $this->assertIdentical($user->profile_bands[1]->value, 'Eagles'); + $this->assertIdentical($user->profile_bands[2]->value, 'Elton John'); + $this->assertIdentical($user->profile_bands[3]->value, 'Lemonheads'); + $this->assertIdentical($user->profile_bands[4]->value, 'Rolling Stones'); + $this->assertIdentical($user->profile_bands[5]->value, 'Queen'); + $this->assertIdentical($user->profile_bands[6]->value, 'The White Stripes'); + $this->assertIdentical($user->profile_birthdate->value, '1974-06-02'); $user = User::load(8); - $this->assertEqual($user->profile_sold_to->value, 'Forward/slash'); + $this->assertIdentical($user->profile_sold_to->value, 'Forward/slash'); $user = User::load(15); - $this->assertEqual($user->profile_sold_to->value, 'Dot.in.the.middle'); + $this->assertIdentical($user->profile_sold_to->value, 'Dot.in.the.middle'); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserRoleTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserRoleTest.php index ec08766..294fc10 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserRoleTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserRoleTest.php @@ -58,22 +58,22 @@ public function testUserRole() { $migration = entity_load('migration', 'd6_user_role'); $rid = 'anonymous'; $anonymous = Role::load($rid); - $this->assertEqual($anonymous->id(), $rid); - $this->assertEqual($anonymous->getPermissions(), array('migrate test anonymous permission', 'use text format filtered_html')); - $this->assertEqual(array($rid), $migration->getIdMap()->lookupDestinationId(array(1))); + $this->assertIdentical($anonymous->id(), $rid); + $this->assertIdentical($anonymous->getPermissions(), array('migrate test anonymous permission', 'use text format filtered_html')); + $this->assertIdentical(array($rid), $migration->getIdMap()->lookupDestinationId(array(1))); $rid = 'authenticated'; $authenticated = Role::load($rid); - $this->assertEqual($authenticated->id(), $rid); - $this->assertEqual($authenticated->getPermissions(), array('migrate test authenticated permission', 'use text format filtered_html')); - $this->assertEqual(array($rid), $migration->getIdMap()->lookupDestinationId(array(2))); + $this->assertIdentical($authenticated->id(), $rid); + $this->assertIdentical($authenticated->getPermissions(), array('migrate test authenticated permission', 'use text format filtered_html')); + $this->assertIdentical(array($rid), $migration->getIdMap()->lookupDestinationId(array(2))); $rid = 'migrate_test_role_1'; $migrate_test_role_1 = Role::load($rid); - $this->assertEqual($migrate_test_role_1->id(), $rid); - $this->assertEqual($migrate_test_role_1->getPermissions(), array(0 => 'migrate test role 1 test permission', 'use text format full_html')); - $this->assertEqual(array($rid), $migration->getIdMap()->lookupDestinationId(array(3))); + $this->assertIdentical($migrate_test_role_1->id(), $rid); + $this->assertIdentical($migrate_test_role_1->getPermissions(), array(0 => 'migrate test role 1 test permission', 'use text format full_html')); + $this->assertIdentical(array($rid), $migration->getIdMap()->lookupDestinationId(array(3))); $rid = 'migrate_test_role_2'; $migrate_test_role_2 = Role::load($rid); - $this->assertEqual($migrate_test_role_2->getPermissions(), array( + $this->assertIdentical($migrate_test_role_2->getPermissions(), array( 'migrate test role 2 test permission', 'use PHP for settings', 'administer contact forms', @@ -90,12 +90,12 @@ public function testUserRole() { 'administer nodes', 'access content overview', )); - $this->assertEqual($migrate_test_role_2->id(), $rid); - $this->assertEqual(array($rid), $migration->getIdMap()->lookupDestinationId(array(4))); + $this->assertIdentical($migrate_test_role_2->id(), $rid); + $this->assertIdentical(array($rid), $migration->getIdMap()->lookupDestinationId(array(4))); $rid = 'migrate_test_role_3_that_is_long'; $migrate_test_role_3 = Role::load($rid); - $this->assertEqual($migrate_test_role_3->id(), $rid); - $this->assertEqual(array($rid), $migration->getIdMap()->lookupDestinationId(array(5))); + $this->assertIdentical($migrate_test_role_3->id(), $rid); + $this->assertIdentical(array($rid), $migration->getIdMap()->lookupDestinationId(array(5))); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserTest.php index 4a187bc..d7c5c73 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateUserTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateUserTest.php @@ -154,30 +154,30 @@ public function testUser() { $signature_format = $migration_format->getIdMap()->lookupDestinationId(array($source->signature_format)); $user = User::load($source->uid); - $this->assertEqual($user->id(), $source->uid); - $this->assertEqual($user->label(), $source->name); - $this->assertEqual($user->getEmail(), $source->mail); - $this->assertEqual($user->getSignature(), $source->signature); + $this->assertIdentical($user->id(), $source->uid); + $this->assertIdentical($user->label(), $source->name); + $this->assertIdentical($user->getEmail(), $source->mail); + $this->assertIdentical($user->getSignature(), $source->signature); $this->assertEqual($user->getSignatureFormat(), reset($signature_format)); - $this->assertEqual($user->getCreatedTime(), $source->created); - $this->assertEqual($user->getLastAccessedTime(), $source->access); - $this->assertEqual($user->getLastLoginTime(), $source->login); + $this->assertIdentical($user->getCreatedTime(), $source->created); + $this->assertIdentical($user->getLastAccessedTime(), $source->access); + $this->assertIdentical($user->getLastLoginTime(), $source->login); $is_blocked = $source->status == 0; - $this->assertEqual($user->isBlocked(), $is_blocked); + $this->assertIdentical($user->isBlocked(), $is_blocked); // $user->getPreferredLangcode() might fallback to default language if the // user preferred language is not configured on the site. We just want to // test if the value was imported correctly. - $this->assertEqual($user->preferred_langcode->value, $source->language); + $this->assertIdentical($user->preferred_langcode->value, $source->language); $time_zone = $source->expected_timezone ?: \Drupal::config('system.date')->get('timezone.default'); - $this->assertEqual($user->getTimeZone(), $time_zone); - $this->assertEqual($user->getInitialEmail(), $source->init); - $this->assertEqual($user->getRoles(), $roles); + $this->assertIdentical($user->getTimeZone(), $time_zone); + $this->assertIdentical($user->getInitialEmail(), $source->init); + $this->assertIdentical($user->getRoles(), $roles); // We have one empty picture in the data so don't try load that. if (!empty($source->picture)) { // Test the user picture. $file = File::load($user->user_picture->target_id); - $this->assertEqual($file->getFilename(), basename($source->picture)); + $this->assertIdentical($file->getFilename(), basename($source->picture)); } // Use the UI to check if the password has been salted and re-hashed to diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateViewModesTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateViewModesTest.php index 8a7a48c..3d7b006 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateViewModesTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateViewModesTest.php @@ -45,10 +45,10 @@ protected function setUp() { public function testViewModes() { // Test a new view mode. $view_mode = EntityViewMode::load('node.preview'); - $this->assertEqual(is_null($view_mode), FALSE, 'Preview view mode loaded.'); - $this->assertEqual($view_mode->label(), 'Preview', 'View mode has correct label.'); + $this->assertIdentical(is_null($view_mode), FALSE, 'Preview view mode loaded.'); + $this->assertIdentical($view_mode->label(), 'Preview', 'View mode has correct label.'); // Test the Id Map. - $this->assertEqual(array('node', 'preview'), entity_load('migration', 'd6_view_modes')->getIdMap()->lookupDestinationID(array(1))); + $this->assertIdentical(array('node', 'preview'), entity_load('migration', 'd6_view_modes')->getIdMap()->lookupDestinationID(array(1))); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateVocabularyEntityDisplayTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateVocabularyEntityDisplayTest.php index bdb849c..258f502 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateVocabularyEntityDisplayTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateVocabularyEntityDisplayTest.php @@ -74,10 +74,10 @@ protected function setUp() { public function testVocabularyEntityDisplay() { // Test that the field exists. $component = entity_get_display('node', 'page', 'default')->getComponent('tags'); - $this->assertEqual($component['type'], 'taxonomy_term_reference_link'); - $this->assertEqual($component['weight'], 20); + $this->assertIdentical($component['type'], 'taxonomy_term_reference_link'); + $this->assertIdentical($component['weight'], 20); // Test the Id map. - $this->assertEqual(array('node', 'article', 'default', 'tags'), entity_load('migration', 'd6_vocabulary_entity_display')->getIdMap()->lookupDestinationID(array(4, 'article'))); + $this->assertIdentical(array('node', 'article', 'default', 'tags'), entity_load('migration', 'd6_vocabulary_entity_display')->getIdMap()->lookupDestinationID(array(4, 'article'))); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateVocabularyEntityFormDisplayTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateVocabularyEntityFormDisplayTest.php index 31759aa..a9e4efd 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateVocabularyEntityFormDisplayTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateVocabularyEntityFormDisplayTest.php @@ -75,10 +75,10 @@ protected function setUp() { public function testVocabularyEntityFormDisplay() { // Test that the field exists. $component = entity_get_form_display('node', 'page', 'default')->getComponent('tags'); - $this->assertEqual($component['type'], 'options_select'); - $this->assertEqual($component['weight'], 20); + $this->assertIdentical($component['type'], 'options_select'); + $this->assertIdentical($component['weight'], 20); // Test the Id map. - $this->assertEqual(array('node', 'article', 'default', 'tags'), entity_load('migration', 'd6_vocabulary_entity_form_display')->getIdMap()->lookupDestinationID(array(4, 'article'))); + $this->assertIdentical(array('node', 'article', 'default', 'tags'), entity_load('migration', 'd6_vocabulary_entity_form_display')->getIdMap()->lookupDestinationID(array(4, 'article'))); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateVocabularyFieldInstanceTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateVocabularyFieldInstanceTest.php index 85889d6..f421afa 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateVocabularyFieldInstanceTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateVocabularyFieldInstanceTest.php @@ -85,14 +85,14 @@ public function testVocabularyFieldInstance() { // Test that the field exists. $field_id = 'node.article.tags'; $field = FieldConfig::load($field_id); - $this->assertEqual($field->id(), $field_id, 'Field instance exists on article bundle.'); + $this->assertIdentical($field->id(), $field_id, 'Field instance exists on article bundle.'); // Test the page bundle as well. $field_id = 'node.page.tags'; $field = FieldConfig::load($field_id); - $this->assertEqual($field->id(), $field_id, 'Field instance exists on page bundle.'); + $this->assertIdentical($field->id(), $field_id, 'Field instance exists on page bundle.'); - $this->assertEqual(array('node', 'article', 'tags'), entity_load('migration', 'd6_vocabulary_field_instance')->getIdMap()->lookupDestinationID(array(4, 'article'))); + $this->assertIdentical(array('node', 'article', 'tags'), entity_load('migration', 'd6_vocabulary_field_instance')->getIdMap()->lookupDestinationID(array(4, 'article'))); } } diff --git a/core/modules/migrate_drupal/src/Tests/d6/MigrateVocabularyFieldTest.php b/core/modules/migrate_drupal/src/Tests/d6/MigrateVocabularyFieldTest.php index 1d261c3..b38084e 100644 --- a/core/modules/migrate_drupal/src/Tests/d6/MigrateVocabularyFieldTest.php +++ b/core/modules/migrate_drupal/src/Tests/d6/MigrateVocabularyFieldTest.php @@ -60,10 +60,10 @@ public function testVocabularyField() { // Test that the field exists. $field_storage_id = 'node.tags'; $field_storage = entity_load('field_storage_config', $field_storage_id); - $this->assertEqual($field_storage->id(), $field_storage_id); + $this->assertIdentical($field_storage->id(), $field_storage_id); $settings = $field_storage->getSettings(); - $this->assertEqual('tags', $settings['allowed_values'][0]['vocabulary'], "Vocabulary has correct settings."); - $this->assertEqual(array('node', 'tags'), entity_load('migration', 'd6_vocabulary_field')->getIdMap()->lookupDestinationID(array(4)), "Test IdMap"); + $this->assertIdentical('tags', $settings['allowed_values'][0]['vocabulary'], "Vocabulary has correct settings."); + $this->assertIdentical(array('node', 'tags'), entity_load('migration', 'd6_vocabulary_field')->getIdMap()->lookupDestinationID(array(4)), "Test IdMap"); } }