File tree Expand file tree Collapse file tree
tests/src/Kernel/DataProducer Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1414 fail-fast : false
1515 matrix :
1616 php-versions : ['7.3', '7.4', '8.0']
17- drupal-core : ['9.2 .x']
17+ drupal-core : ['9.3 .x']
1818 include :
1919 # Extra run to also test on latest Drupal 8 and PHP 7.2.
2020 - php-versions : ' 7.2'
Original file line number Diff line number Diff line change @@ -46,6 +46,13 @@ parameters:
4646 - """
4747 #^Call to deprecated function file_munge_filename\\(\\)#
4848 """
49+ - """
50+ # ^Call to deprecated function drupal_get_path\\(\\)#
51+ """
52+ - """
53+ #^Call to deprecated function file_create_url\\(\\)#
54+ """
55+ - "#^Call to an undefined method Drupal\\\\Tests\\\\graphql\\\\Kernel\\\\DataProducer\\\\EntityTest\\:\\:assertMatchesRegularExpression\\ (\\ )\\.$ #"
4956 # Drupal allows object property access to custom fields, so we cannot fix
5057 # that.
5158 - "#^Property Drupal\\\\.+ \\ (Drupal\\\\Core\\\\Field\\\\FieldItemListInterface\\ ) does not accept .+\\.$ #"
Original file line number Diff line number Diff line change @@ -377,7 +377,14 @@ public function testResolveEntityRendered(): void {
377377
378378 // @todo Add metadata check.
379379 // $this->assertContains('node:1', $metadata->getCacheTags());
380- $ this ->assertStringContainsString ('<a href="/node/1" rel="bookmark"><span> ' . $ this ->node ->getTitle () . '</span> ' , $ result );
380+ // Rendered output is slightly different in Drupal 8 vs. 9.
381+ [$ version ] = explode ('. ' , \Drupal::VERSION , 2 );
382+ if ($ version == 8 ) {
383+ $ this ->assertStringContainsString ('<a href="/node/1" rel="bookmark"><span> ' . $ this ->node ->getTitle () . '</span> ' , $ result );
384+ }
385+ else {
386+ $ this ->assertMatchesRegularExpression ('#<a href="/node/1" rel="bookmark">\s*<span> ' . $ this ->node ->getTitle () . '</span># ' , $ result );
387+ }
381388 }
382389
383390}
You can’t perform that action at this time.
0 commit comments