com phpruntests: overriding writeExecutableFile: src/testcase/sections/executablesections/rtFileExternalSection.php
src/testcase/sections/rtExecutableSection.php

From: Date: Sun, 17 May 2009 11:47:27 +0000
Subject: com phpruntests: overriding writeExecutableFile: src/testcase/sections/executablesections/rtFileExternalSection.php
src/testcase/sections/rtExecutableSection.php
Groups: php.qa 
Request: Send a blank email to php-qa+get-66454@lists.php.net to get a copy of this message
Commit: d134bb32ff9df2d34d6163d2d995921c6fba009b Author: Zoe Slattery <zoe@php.net> Sun, 17 May 2009 11:47:27 +0000 Parents: 8d32f623b834c8df33107c87a84d519b2c1bd7dc Branches: master Link: http://git.php.net/?p=phpruntests.git;a=commitdiff;h=d134bb32ff9df2d34d6163d2d995921c6fba009b Log: overriding writeExecutableFile Changed paths: M src/testcase/sections/executablesections/rtFileExternalSection.php M src/testcase/sections/rtExecutableSection.php Diff: diff --git a/src/testcase/sections/executablesections/rtFileExternalSection.php b/src/testcase/sections/executablesections/rtFileExternalSection.php index 040d052..af18158 100644 --- a/src/testcase/sections/executablesections/rtFileExternalSection.php +++ b/src/testcase/sections/executablesections/rtFileExternalSection.php @@ -52,5 +52,9 @@ class rtFileExternalSection extends rtFileSection return false; } + + public function writeExecutableFile() { + file_put_contents($this->fileName, (binary) $this->sectionContents[0]); + } } ?> diff --git a/src/testcase/sections/rtExecutableSection.php b/src/testcase/sections/rtExecutableSection.php index a9238e6..24c0424 100644 --- a/src/testcase/sections/rtExecutableSection.php +++ b/src/testcase/sections/rtExecutableSection.php @@ -14,7 +14,7 @@ abstract class rtExecutableSection extends rtSection protected function writeExecutableFile() { - $contentsAsString = implode("\n", $this->sectionContents); + $contentsAsString = implode("\n", $this->sectionContents) . "\n"; file_put_contents($this->fileName, (binary) $contentsAsString); }

« previous php.qa (#66454) next »