You are here

public function CommentTest::testPrepareCommentDeprecation in Drupal 9

@group legacy

File

core/modules/comment/tests/src/Kernel/Plugin/migrate/source/d6/CommentTest.php, line 24

Class

CommentTest
Tests D6 comment source plugin.

Namespace

Drupal\Tests\comment\Kernel\Plugin\migrate\source\d6

Code

public function testPrepareCommentDeprecation() {
  $this
    ->expectDeprecation('Drupal\\comment\\Plugin\\migrate\\source\\d6\\Comment::prepareComment() is deprecated in drupal:9.3.0 and is removed from drupal:10.0.0. No direct replacement is provided. See https://www.drupal.org/node/3221964');
  $migration = $this
    ->createMock('Drupal\\migrate\\Plugin\\MigrationInterface');
  $mgr = \Drupal::service('plugin.manager.migrate.source');
  $plugin = $mgr
    ->createInstance('d6_comment_test', [], $migration);
  $plugin
    ->prepareComment(new Row());
}