You are here

private function PHPUnit_Extensions_PhptTestCase::render in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/phpunit/phpunit/src/Extensions/PhptTestCase.php \PHPUnit_Extensions_PhptTestCase::render()

Parameters

string $code:

Return value

string

1 call to PHPUnit_Extensions_PhptTestCase::render()
PHPUnit_Extensions_PhptTestCase::run in vendor/phpunit/phpunit/src/Extensions/PhptTestCase.php
Runs a test and collects its result in a TestResult instance.

File

vendor/phpunit/phpunit/src/Extensions/PhptTestCase.php, line 211

Class

PHPUnit_Extensions_PhptTestCase
Runner for PHPT test cases.

Code

private function render($code) {
  return str_replace(array(
    '__DIR__',
    '__FILE__',
  ), array(
    "'" . dirname($this->filename) . "'",
    "'" . $this->filename . "'",
  ), $code);
}