diff -u b/tests/src/Kernel/Processor/RenderedItemTest.php b/tests/src/Kernel/Processor/RenderedItemTest.php --- b/tests/src/Kernel/Processor/RenderedItemTest.php +++ b/tests/src/Kernel/Processor/RenderedItemTest.php @@ -243,7 +243,7 @@ // object, which contains a string (not, for example, some markup object). $this->assertInstanceOf('Drupal\search_api\Plugin\search_api\data_type\value\TextValueInterface', $values[0], "$type item $entity_id rendered value is properly wrapped in a text value object."); $field_value = $values[0]->getText(); - $this->assertInternalType('string', $field_value, "$type item $entity_id rendered value is a string."); + $this->assertSame('string', gettype($field_value), "$type item $entity_id rendered value is a string."); $this->assertEquals(1, count($values), "$type item $entity_id rendered value is a single value."); switch ($datasource_id) { diff -u b/tests/src/Kernel/System/CommandHelperTest.php b/tests/src/Kernel/System/CommandHelperTest.php --- b/tests/src/Kernel/System/CommandHelperTest.php +++ b/tests/src/Kernel/System/CommandHelperTest.php @@ -119,7 +119,7 @@ */ public function testListCommand() { $results = $this->systemUnderTest->indexListCommand(); - $this->assertInternalType('array', $results); + $this->assertSame('array', gettype($results)); $this->assertCount(2, $results); $this->assertArrayHasKey('test_index', $results); $this->assertArrayHasKey('second_index', $results); @@ -137,7 +137,7 @@ $index->delete(); $results = $this->systemUnderTest->indexListCommand(); - $this->assertInternalType('array', $results); + $this->assertSame('array', gettype($results)); $this->assertArrayNotHasKey('test_index', $results); $this->assertArrayHasKey('second_index', $results); } @@ -149,7 +149,7 @@ */ public function testStatusCommand() { $results = $this->systemUnderTest->indexStatusCommand(); - $this->assertInternalType('array', $results); + $this->assertSame('array', gettype($results)); $this->assertCount(2, $results); $this->assertArrayHasKey('test_index', $results); $this->assertArrayHasKey('id', $results['test_index']); @@ -278,7 +278,7 @@ */ public function testServerListCommand() { $result = $this->systemUnderTest->serverListCommand(); - $this->assertInternalType('array', $result); + $this->assertSame('array', gettype($result)); $this->assertCount(1, $result); $this->assertArrayHasKey('test_server', $result); $this->assertSame('test_server', $result['test_server']['id']); @@ -291,7 +291,7 @@ $server->save(); $result = $this->systemUnderTest->serverListCommand(); - $this->assertInternalType('array', $result); + $this->assertSame('array', gettype($result)); $this->assertCount(1, $result); $this->assertArrayHasKey('test_server', $result); $this->assertSame('test_server', $result['test_server']['id']); only in patch2: unchanged: --- a/tests/src/Functional/IntegrationTest.php +++ b/tests/src/Functional/IntegrationTest.php @@ -1045,7 +1045,7 @@ class IntegrationTest extends SearchApiBrowserTestBase { // Find the "Remove" link for the "body" field. $links = $this->xpath('//a[@data-drupal-selector=:id]', [':id' => 'edit-fields-body-remove']); $this->assertNotEmpty($links, 'Found "Remove" link for body field'); - $this->assertInternalType('array', $links); + $this->assertSame('array', gettype($links)); $url_target = $this->getAbsoluteUrl($links[0]->getAttribute('href')); $this->drupalGet($url_target); $this->drupalGet($this->getIndexPath('fields')); @@ -1106,7 +1106,7 @@ class IntegrationTest extends SearchApiBrowserTestBase { // Find the "Remove" link for the "title" field. $links = $this->xpath('//a[@data-drupal-selector=:id]', [':id' => 'edit-fields-title-remove']); $this->assertNotEmpty($links, 'Found "Remove" link for title field'); - $this->assertInternalType('array', $links); + $this->assertSame('array', gettype($links)); $url_target = $this->getAbsoluteUrl($links[0]->getAttribute('href')); $this->drupalGet($url_target); only in patch2: unchanged: --- a/tests/src/Kernel/System/SerializationTest.php +++ b/tests/src/Kernel/System/SerializationTest.php @@ -132,7 +132,7 @@ class SerializationTest extends KernelTestBase { $query = $this->createTestQuery(); // Since Drupal's DB layer sometimes has problems with side-effects of // __toString(), we here try to make sure this won't happen to us. - $this->assertInternalType('string', (string) $query); + $this->assertSame('string', gettype((string) $query)); $clone = clone $query;