Loading core/modules/language/tests/src/Kernel/Migrate/d7/MigrateLanguageContentMenuSettingsTest.php +1 −1 Original line number Diff line number Diff line Loading @@ -45,7 +45,7 @@ public function testLanguageContentMenu() { $this->assertSame('menu_link_content', $config->getTargetEntityTypeId()); $this->assertSame('menu_link_content', $config->getTargetBundle()); $this->assertSame(LanguageInterface::LANGCODE_SITE_DEFAULT, $config->getDefaultLangcode()); $this->assertSame(TRUE, $config->isLanguageAlterable()); $this->assertTrue($config->isLanguageAlterable()); $settings = [ 'enabled' => TRUE, 'bundle_settings' => [ Loading core/modules/migrate/tests/src/Kernel/MigrateEmbeddedDataTest.php +1 −1 Original line number Diff line number Diff line Loading @@ -58,7 +58,7 @@ public function testEmbeddedData() { $this->assertSame($data_rows, $results); // Validate the public APIs. $this->assertSame(count($data_rows), $source->count()); $this->assertSameSize($data_rows, $source); $this->assertSame($ids, $source->getIds()); $expected_fields = [ 'key' => 'key', Loading core/modules/migrate/tests/src/Kernel/Plugin/source/MigrationSourceCacheTest.php +4 −4 Original line number Diff line number Diff line Loading @@ -78,8 +78,8 @@ public function testCacheCountsNotContaminated() { $this->assertSame(2, $migration_2_source->count(TRUE)); // Verify correct counts are cached. $this->assertSame(1, $migration_1_source->count()); $this->assertSame(2, $migration_2_source->count()); $this->assertCount(1, $migration_1_source); $this->assertCount(2, $migration_2_source); // Verify the cache keys are different. $cache_key_property = new \ReflectionProperty(SourcePluginBase::class, 'cacheKey'); Loading Loading @@ -108,14 +108,14 @@ public function testCacheCountsUsed() { ]; $migration = $this->migrationPluginManager->createStubMigration($migration_definition); $migration_source = $migration->getSourcePlugin(); $this->assertSame(2, $migration_source->count()); $this->assertCount(2, $migration_source); // Pollute the cache. $cache_key_property = new \ReflectionProperty($migration_source, 'cacheKey'); $cache_key_property->setAccessible(TRUE); $cache_key = $cache_key_property->getValue($migration_source); \Drupal::cache('migrate')->set($cache_key, 7); $this->assertSame(7, $migration_source->count()); $this->assertCount(7, $migration_source); $this->assertSame(2, $migration_source->count(TRUE)); } Loading core/modules/rest/tests/src/Functional/Views/StyleSerializerTest.php +1 −1 Original line number Diff line number Diff line Loading @@ -721,7 +721,7 @@ public function testFieldapiField() { $this->executeView($view); $result = Json::decode($this->drupalGet('test/serialize/node-field', ['query' => ['_format' => 'json']])); $this->assertSame($node->body->count(), count($result[2]['body']), 'Expected count of values'); $this->assertCount($node->body->count(), $result[2]['body']); $this->assertEquals($result[2]['body'], array_map(function ($item) { return $item['value']; }, $node->body->getValue()), 'Expected raw body values found.'); Loading core/modules/system/tests/src/Unit/Event/SecurityFileUploadEventSubscriberTest.php +2 −2 Original line number Diff line number Diff line Loading @@ -114,7 +114,7 @@ public function testSanitizeNameNoMunge(string $filename, string $allowed_extens // Check the results of the configured sanitization. $this->assertSame($filename, $event->getFilename()); $this->assertSame(FALSE, $event->isSecurityRename()); $this->assertFalse($event->isSecurityRename()); $config_factory = $this->getConfigFactoryStub([ 'system.file' => [ Loading @@ -128,7 +128,7 @@ public function testSanitizeNameNoMunge(string $filename, string $allowed_extens // Check the results of the configured sanitization. $this->assertSame($filename, $event->getFilename()); $this->assertSame(FALSE, $event->isSecurityRename()); $this->assertFalse($event->isSecurityRename()); } /** Loading Loading
core/modules/language/tests/src/Kernel/Migrate/d7/MigrateLanguageContentMenuSettingsTest.php +1 −1 Original line number Diff line number Diff line Loading @@ -45,7 +45,7 @@ public function testLanguageContentMenu() { $this->assertSame('menu_link_content', $config->getTargetEntityTypeId()); $this->assertSame('menu_link_content', $config->getTargetBundle()); $this->assertSame(LanguageInterface::LANGCODE_SITE_DEFAULT, $config->getDefaultLangcode()); $this->assertSame(TRUE, $config->isLanguageAlterable()); $this->assertTrue($config->isLanguageAlterable()); $settings = [ 'enabled' => TRUE, 'bundle_settings' => [ Loading
core/modules/migrate/tests/src/Kernel/MigrateEmbeddedDataTest.php +1 −1 Original line number Diff line number Diff line Loading @@ -58,7 +58,7 @@ public function testEmbeddedData() { $this->assertSame($data_rows, $results); // Validate the public APIs. $this->assertSame(count($data_rows), $source->count()); $this->assertSameSize($data_rows, $source); $this->assertSame($ids, $source->getIds()); $expected_fields = [ 'key' => 'key', Loading
core/modules/migrate/tests/src/Kernel/Plugin/source/MigrationSourceCacheTest.php +4 −4 Original line number Diff line number Diff line Loading @@ -78,8 +78,8 @@ public function testCacheCountsNotContaminated() { $this->assertSame(2, $migration_2_source->count(TRUE)); // Verify correct counts are cached. $this->assertSame(1, $migration_1_source->count()); $this->assertSame(2, $migration_2_source->count()); $this->assertCount(1, $migration_1_source); $this->assertCount(2, $migration_2_source); // Verify the cache keys are different. $cache_key_property = new \ReflectionProperty(SourcePluginBase::class, 'cacheKey'); Loading Loading @@ -108,14 +108,14 @@ public function testCacheCountsUsed() { ]; $migration = $this->migrationPluginManager->createStubMigration($migration_definition); $migration_source = $migration->getSourcePlugin(); $this->assertSame(2, $migration_source->count()); $this->assertCount(2, $migration_source); // Pollute the cache. $cache_key_property = new \ReflectionProperty($migration_source, 'cacheKey'); $cache_key_property->setAccessible(TRUE); $cache_key = $cache_key_property->getValue($migration_source); \Drupal::cache('migrate')->set($cache_key, 7); $this->assertSame(7, $migration_source->count()); $this->assertCount(7, $migration_source); $this->assertSame(2, $migration_source->count(TRUE)); } Loading
core/modules/rest/tests/src/Functional/Views/StyleSerializerTest.php +1 −1 Original line number Diff line number Diff line Loading @@ -721,7 +721,7 @@ public function testFieldapiField() { $this->executeView($view); $result = Json::decode($this->drupalGet('test/serialize/node-field', ['query' => ['_format' => 'json']])); $this->assertSame($node->body->count(), count($result[2]['body']), 'Expected count of values'); $this->assertCount($node->body->count(), $result[2]['body']); $this->assertEquals($result[2]['body'], array_map(function ($item) { return $item['value']; }, $node->body->getValue()), 'Expected raw body values found.'); Loading
core/modules/system/tests/src/Unit/Event/SecurityFileUploadEventSubscriberTest.php +2 −2 Original line number Diff line number Diff line Loading @@ -114,7 +114,7 @@ public function testSanitizeNameNoMunge(string $filename, string $allowed_extens // Check the results of the configured sanitization. $this->assertSame($filename, $event->getFilename()); $this->assertSame(FALSE, $event->isSecurityRename()); $this->assertFalse($event->isSecurityRename()); $config_factory = $this->getConfigFactoryStub([ 'system.file' => [ Loading @@ -128,7 +128,7 @@ public function testSanitizeNameNoMunge(string $filename, string $allowed_extens // Check the results of the configured sanitization. $this->assertSame($filename, $event->getFilename()); $this->assertSame(FALSE, $event->isSecurityRename()); $this->assertFalse($event->isSecurityRename()); } /** Loading