diff --git a/src/Symfony/Component/Process/Process.php b/src/Symfony/Component/Process/Process.php index 9610f0899e86f..46a3de602d74e 100644 --- a/src/Symfony/Component/Process/Process.php +++ b/src/Symfony/Component/Process/Process.php @@ -1078,8 +1078,6 @@ public function getInput() * @return self The current Process instance * * @throws LogicException In case the process is running - * - * Passing an object as an input is deprecated since version 2.5 and will be removed in 3.0. */ public function setInput($input) { diff --git a/src/Symfony/Component/Process/ProcessBuilder.php b/src/Symfony/Component/Process/ProcessBuilder.php index a782fd69e94dd..041ac38f5b04b 100644 --- a/src/Symfony/Component/Process/ProcessBuilder.php +++ b/src/Symfony/Component/Process/ProcessBuilder.php @@ -172,8 +172,6 @@ public function addEnvironmentVariables(array $variables) * @return ProcessBuilder * * @throws InvalidArgumentException In case the argument is invalid - * - * Passing an object as an input is deprecated since version 2.5 and will be removed in 3.0. */ public function setInput($input) { diff --git a/src/Symfony/Component/Process/ProcessUtils.php b/src/Symfony/Component/Process/ProcessUtils.php index dd0a74373c879..9ce461bf7cfd7 100644 --- a/src/Symfony/Component/Process/ProcessUtils.php +++ b/src/Symfony/Component/Process/ProcessUtils.php @@ -83,8 +83,6 @@ public static function escapeArgument($argument) * @return string The validated input * * @throws InvalidArgumentException In case the input is not valid - * - * Passing an object as an input is deprecated since version 2.5 and will be removed in 3.0. */ public static function validateInput($caller, $input) { @@ -95,12 +93,6 @@ public static function validateInput($caller, $input) if (is_scalar($input)) { return (string) $input; } - // deprecated as of Symfony 2.5, to be removed in 3.0 - if (is_object($input) && method_exists($input, '__toString')) { - trigger_error('Passing an object as an input is deprecated since version 2.5 and will be removed in 3.0.', E_USER_DEPRECATED); - - return (string) $input; - } throw new InvalidArgumentException(sprintf('%s only accepts strings or stream resources.', $caller)); } diff --git a/src/Symfony/Component/Process/Tests/AbstractProcessTest.php b/src/Symfony/Component/Process/Tests/AbstractProcessTest.php index 8aa3765245f02..8fa93c9f0e1e8 100644 --- a/src/Symfony/Component/Process/Tests/AbstractProcessTest.php +++ b/src/Symfony/Component/Process/Tests/AbstractProcessTest.php @@ -232,26 +232,6 @@ public function provideInputValues() ); } - /** - * @dataProvider provideLegacyInputValues - * @group legacy - */ - public function testLegacyValidInput($expected, $value) - { - $this->iniSet('error_reporting', -1 & ~E_USER_DEPRECATED); - - $process = $this->getProcess('php -v'); - $process->setInput($value); - $this->assertSame($expected, $process->getInput()); - } - - public function provideLegacyInputValues() - { - return array( - array('stringifiable', new Stringifiable()), - ); - } - public function chainedCommandsOutputProvider() { if ('\\' === DIRECTORY_SEPARATOR) { @@ -1191,14 +1171,6 @@ public function methodProvider() abstract protected function getProcess($commandline, $cwd = null, array $env = null, $input = null, $timeout = 60, array $options = array()); } -class Stringifiable -{ - public function __toString() - { - return 'stringifiable'; - } -} - class NonStringifiable { }