You are here

public function ExecutableFinderTest::testFindWithExtraDirs in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/symfony/process/Tests/ExecutableFinderTest.php \Symfony\Component\Process\Tests\ExecutableFinderTest::testFindWithExtraDirs()

File

vendor/symfony/process/Tests/ExecutableFinderTest.php, line 71

Class

ExecutableFinderTest
@author Chris Smith <chris@cs278.org>

Namespace

Symfony\Component\Process\Tests

Code

public function testFindWithExtraDirs() {
  if (!defined('PHP_BINARY')) {
    $this
      ->markTestSkipped('Requires the PHP_BINARY constant');
  }
  if (ini_get('open_basedir')) {
    $this
      ->markTestSkipped('Cannot test when open_basedir is set');
  }
  $this
    ->setPath('');
  $extraDirs = array(
    dirname(PHP_BINARY),
  );
  $finder = new ExecutableFinder();
  $result = $finder
    ->find($this
    ->getPhpBinaryName(), null, $extraDirs);
  $this
    ->assertSamePath(PHP_BINARY, $result);
}