Skip to content

Commit

Permalink
Migrate to static data providers using rector/rector
Browse files Browse the repository at this point in the history
  • Loading branch information
OskarStark authored and nicolas-grekas committed Feb 14, 2023
1 parent f7f1cf1 commit 4019350
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions Tests/ProcessTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ public function testInvalidInput($value)
$process->setInput($value);
}

public function provideInvalidInputValues()
public static function provideInvalidInputValues()
{
return [
[[]],
Expand All @@ -319,7 +319,7 @@ public function testValidInput($expected, $value)
$this->assertSame($expected, $process->getInput());
}

public function provideInputValues()
public static function provideInputValues()
{
return [
[null, null],
Expand All @@ -328,7 +328,7 @@ public function provideInputValues()
];
}

public function chainedCommandsOutputProvider()
public static function chainedCommandsOutputProvider()
{
if ('\\' === \DIRECTORY_SEPARATOR) {
return [
Expand Down Expand Up @@ -422,7 +422,7 @@ public function testIncrementalOutput($getOutput, $getIncrementalOutput, $uri)
fclose($h);
}

public function provideIncrementalOutput()
public static function provideIncrementalOutput()
{
return [
['getOutput', 'getIncrementalOutput', 'php://stdout'],
Expand Down Expand Up @@ -957,7 +957,7 @@ public function testMethodsThatNeedARunningProcess($method)
$process->{$method}();
}

public function provideMethodsThatNeedARunningProcess()
public static function provideMethodsThatNeedARunningProcess()
{
return [
['getOutput'],
Expand Down Expand Up @@ -988,7 +988,7 @@ public function testMethodsThatNeedATerminatedProcess($method)
throw $e;
}

public function provideMethodsThatNeedATerminatedProcess()
public static function provideMethodsThatNeedATerminatedProcess()
{
return [
['hasBeenSignaled'],
Expand Down Expand Up @@ -1093,7 +1093,7 @@ public function testGetOutputWhileDisabled($fetchMethod)
$p->{$fetchMethod}();
}

public function provideOutputFetchingMethods()
public static function provideOutputFetchingMethods()
{
return [
['getOutput'],
Expand Down Expand Up @@ -1130,7 +1130,7 @@ public function testTermSignalTerminatesProcessCleanly()
$this->assertTrue(true, 'A call to signal() is not expected to cause wait() to throw a RuntimeException');
}

public function responsesCodeProvider()
public static function responsesCodeProvider()
{
return [
// expected output / getter / code to execute
Expand All @@ -1140,7 +1140,7 @@ public function responsesCodeProvider()
];
}

public function pipesCodeProvider()
public static function pipesCodeProvider()
{
$variations = [
'fwrite(STDOUT, $in = file_get_contents(\'php://stdin\')); fwrite(STDERR, $in);',
Expand Down Expand Up @@ -1183,7 +1183,7 @@ public function testIncrementalOutputDoesNotRequireAnotherCall($stream, $method)
$process->stop();
}

public function provideVariousIncrementals()
public static function provideVariousIncrementals()
{
return [
['php://stdout', 'getIncrementalOutput'],
Expand Down Expand Up @@ -1449,7 +1449,7 @@ public function testRawCommandLine()
$this->assertSame($expected, str_replace('Standard input code', '-', $p->getOutput()));
}

public function provideEscapeArgument()
public static function provideEscapeArgument()
{
yield ['a"b%c%'];
yield ['a"b^c^'];
Expand Down

0 comments on commit 4019350

Please sign in to comment.