public function ExecManagerTest::testExecManagerCommandNotFound in ImageMagick 8.3
Same name and namespace in other branches
- 8.2 tests/src/Kernel/ExecManagerTest.php \Drupal\Tests\imagemagick\Kernel\ExecManagerTest::testExecManagerCommandNotFound()
Test missing command on ExecManager.
File
- tests/
src/ Kernel/ ExecManagerTest.php, line 22
Class
- ExecManagerTest
- Tests for ImagemagickExecManager.
Namespace
Drupal\Tests\imagemagick\KernelCode
public function testExecManagerCommandNotFound() : void {
$exec_manager = \Drupal::service('imagemagick.exec_manager');
$output = '';
$error = '';
$expected = substr(PHP_OS, 0, 3) !== 'WIN' ? 127 : 1;
$ret = $exec_manager
->runOsShell('pinkpanther', '-inspector Clouseau', 'blake', $output, $error);
$this
->assertEquals($expected, $ret, $error);
}