You are here

public function BlockVisibilityTest::testTransformPhpDisabled in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/modules/block/tests/src/Unit/Plugin/migrate/process/BlockVisibilityTest.php \Drupal\Tests\block\Unit\Plugin\migrate\process\BlockVisibilityTest::testTransformPhpDisabled()

@covers ::transform

File

core/modules/block/tests/src/Unit/Plugin/migrate/process/BlockVisibilityTest.php, line 82
Contains \Drupal\Tests\block\Unit\Plugin\migrate\process\BlockVisibilityTest.

Class

BlockVisibilityTest
Tests the block_visibility process plugin.

Namespace

Drupal\Tests\block\Unit\Plugin\migrate\process

Code

public function testTransformPhpDisabled() {
  $this->moduleHandler
    ->moduleExists('php')
    ->willReturn(FALSE);
  $transformed_value = $this->plugin
    ->transform([
    2,
    '<?php',
    [],
  ], $this->migrateExecutable, $this->row, 'destinationproperty');
  $this
    ->assertEmpty($transformed_value);
}