@@ -155,7 +155,7 @@ |
||
155 | 155 | ); |
156 | 156 | } |
157 | 157 | |
158 | - $full_option = '--' . \preg_replace('/={1,2}$/', '', $long_opt); |
|
158 | + $full_option = '--'.\preg_replace('/={1,2}$/', '', $long_opt); |
|
159 | 159 | $opts[] = [$full_option, $opt_arg]; |
160 | 160 | |
161 | 161 | return; |
@@ -1,4 +1,4 @@ discard block |
||
1 | -<?php declare(strict_types=1); |
|
1 | +<?php declare(strict_types = 1); |
|
2 | 2 | /* |
3 | 3 | * This file is part of PHPUnit. |
4 | 4 | * |
@@ -18,7 +18,7 @@ discard block |
||
18 | 18 | { |
19 | 19 | public function render(TestSuite $suite): string |
20 | 20 | { |
21 | - $buffer = 'Available test(s):' . PHP_EOL; |
|
21 | + $buffer = 'Available test(s):'.PHP_EOL; |
|
22 | 22 | |
23 | 23 | foreach (new \RecursiveIteratorIterator($suite->getIterator()) as $test) { |
24 | 24 | if ($test instanceof TestCase) { |
@@ -34,7 +34,7 @@ discard block |
||
34 | 34 | } |
35 | 35 | |
36 | 36 | $buffer .= \sprintf( |
37 | - ' - %s' . PHP_EOL, |
|
37 | + ' - %s'.PHP_EOL, |
|
38 | 38 | $name |
39 | 39 | ); |
40 | 40 | } |
@@ -34,14 +34,14 @@ |
||
34 | 34 | // We don't want to load the Test.php file here, so skip it if it found that. |
35 | 35 | // PHP prioritizes the include_path setting, so if the current directory is in there, it will first look in the |
36 | 36 | // current working directory. |
37 | - $localFile = __DIR__ . DIRECTORY_SEPARATOR . $filename; |
|
37 | + $localFile = __DIR__.DIRECTORY_SEPARATOR.$filename; |
|
38 | 38 | |
39 | 39 | // @see https://github.com/sebastianbergmann/phpunit/pull/2751 |
40 | 40 | $isReadable = @\fopen($includePathFilename, 'r') !== false; |
41 | 41 | |
42 | 42 | if (!$includePathFilename || !$isReadable || $includePathFilename === $localFile) { |
43 | 43 | throw new Exception( |
44 | - \sprintf('Cannot open file "%s".' . "\n", $filename) |
|
44 | + \sprintf('Cannot open file "%s".'."\n", $filename) |
|
45 | 45 | ); |
46 | 46 | } |
47 | 47 |
@@ -35,6 +35,6 @@ |
||
35 | 35 | ['_', '\\'], |
36 | 36 | DIRECTORY_SEPARATOR, |
37 | 37 | $className |
38 | - ) . '.php'; |
|
38 | + ).'.php'; |
|
39 | 39 | } |
40 | 40 | } |
@@ -38,6 +38,6 @@ |
||
38 | 38 | |
39 | 39 | public function getCommand(array $settings, $file = null) |
40 | 40 | { |
41 | - return '"' . parent::getCommand($settings, $file) . '"'; |
|
41 | + return '"'.parent::getCommand($settings, $file).'"'; |
|
42 | 42 | } |
43 | 43 | } |
@@ -7,4 +7,4 @@ |
||
7 | 7 | * For the full copyright and license information, please view the LICENSE |
8 | 8 | * file that was distributed with this source code. |
9 | 9 | */ |
10 | -eval('?>' . \file_get_contents('php://stdin')); |
|
10 | +eval('?>'.\file_get_contents('php://stdin')); |
@@ -223,16 +223,16 @@ discard block |
||
223 | 223 | $command .= ' -qrr '; |
224 | 224 | |
225 | 225 | if ($file) { |
226 | - $command .= '-e ' . \escapeshellarg($file); |
|
226 | + $command .= '-e '.\escapeshellarg($file); |
|
227 | 227 | } else { |
228 | - $command .= \escapeshellarg(__DIR__ . '/eval-stdin.php'); |
|
228 | + $command .= \escapeshellarg(__DIR__.'/eval-stdin.php'); |
|
229 | 229 | } |
230 | 230 | } elseif ($file) { |
231 | - $command .= ' -f ' . \escapeshellarg($file); |
|
231 | + $command .= ' -f '.\escapeshellarg($file); |
|
232 | 232 | } |
233 | 233 | |
234 | 234 | if ($this->args) { |
235 | - $command .= ' -- ' . $this->args; |
|
235 | + $command .= ' -- '.$this->args; |
|
236 | 236 | } |
237 | 237 | |
238 | 238 | if (true === $this->stderrRedirection) { |
@@ -264,7 +264,7 @@ discard block |
||
264 | 264 | $buffer = ''; |
265 | 265 | |
266 | 266 | foreach ($settings as $setting) { |
267 | - $buffer .= ' -d ' . $setting; |
|
267 | + $buffer .= ' -d '.$setting; |
|
268 | 268 | } |
269 | 269 | |
270 | 270 | return $buffer; |
@@ -289,7 +289,7 @@ discard block |
||
289 | 289 | $time |
290 | 290 | ); |
291 | 291 | } else { |
292 | - \set_error_handler(function ($errno, $errstr, $errfile, $errline) { |
|
292 | + \set_error_handler(function($errno, $errstr, $errfile, $errline) { |
|
293 | 293 | throw new ErrorException($errstr, $errno, $errno, $errfile, $errline); |
294 | 294 | }); |
295 | 295 |
@@ -46,7 +46,7 @@ discard block |
||
46 | 46 | $result = ''; |
47 | 47 | |
48 | 48 | if (\defined('__PHPUNIT_PHAR__')) { |
49 | - $prefix = 'phar://' . __PHPUNIT_PHAR__ . '/'; |
|
49 | + $prefix = 'phar://'.__PHPUNIT_PHAR__.'/'; |
|
50 | 50 | } |
51 | 51 | |
52 | 52 | for ($i = \count($files) - 1; $i > 0; $i--) { |
@@ -62,7 +62,7 @@ discard block |
||
62 | 62 | } |
63 | 63 | |
64 | 64 | if (!$blacklist->isBlacklisted($file) && \is_file($file)) { |
65 | - $result = 'require_once \'' . $file . "';\n" . $result; |
|
65 | + $result = 'require_once \''.$file."';\n".$result; |
|
66 | 66 | } |
67 | 67 | } |
68 | 68 | |
@@ -79,7 +79,7 @@ discard block |
||
79 | 79 | |
80 | 80 | foreach ($iniSettings as $key => $value) { |
81 | 81 | $result .= \sprintf( |
82 | - '@ini_set(%s, %s);' . "\n", |
|
82 | + '@ini_set(%s, %s);'."\n", |
|
83 | 83 | self::exportVariable($key), |
84 | 84 | self::exportVariable($value) |
85 | 85 | ); |
@@ -99,7 +99,7 @@ discard block |
||
99 | 99 | if (isset($constants['user'])) { |
100 | 100 | foreach ($constants['user'] as $name => $value) { |
101 | 101 | $result .= \sprintf( |
102 | - 'if (!defined(\'%s\')) define(\'%s\', %s);' . "\n", |
|
102 | + 'if (!defined(\'%s\')) define(\'%s\', %s);'."\n", |
|
103 | 103 | $name, |
104 | 104 | $name, |
105 | 105 | self::exportVariable($value) |
@@ -126,7 +126,7 @@ discard block |
||
126 | 126 | } |
127 | 127 | |
128 | 128 | $result .= \sprintf( |
129 | - '$GLOBALS[\'%s\'][\'%s\'] = %s;' . "\n", |
|
129 | + '$GLOBALS[\'%s\'][\'%s\'] = %s;'."\n", |
|
130 | 130 | $superGlobalArray, |
131 | 131 | $key, |
132 | 132 | self::exportVariable($GLOBALS[$superGlobalArray][$key]) |
@@ -141,7 +141,7 @@ discard block |
||
141 | 141 | foreach (\array_keys($GLOBALS) as $key) { |
142 | 142 | if (!\in_array($key, $blacklist) && !$GLOBALS[$key] instanceof Closure) { |
143 | 143 | $result .= \sprintf( |
144 | - '$GLOBALS[\'%s\'] = %s;' . "\n", |
|
144 | + '$GLOBALS[\'%s\'] = %s;'."\n", |
|
145 | 145 | $key, |
146 | 146 | self::exportVariable($GLOBALS[$key]) |
147 | 147 | ); |
@@ -166,8 +166,8 @@ discard block |
||
166 | 166 | return \var_export($variable, true); |
167 | 167 | } |
168 | 168 | |
169 | - return 'unserialize(' . |
|
170 | - \var_export(\serialize($variable), true) . |
|
169 | + return 'unserialize('. |
|
170 | + \var_export(\serialize($variable), true). |
|
171 | 171 | ')'; |
172 | 172 | } |
173 | 173 |
@@ -96,7 +96,7 @@ discard block |
||
96 | 96 | */ |
97 | 97 | public static function handleErrorOnce($severity = E_WARNING) |
98 | 98 | { |
99 | - $terminator = function () { |
|
99 | + $terminator = function() { |
|
100 | 100 | static $expired = false; |
101 | 101 | if (!$expired) { |
102 | 102 | $expired = true; |
@@ -105,7 +105,7 @@ discard block |
||
105 | 105 | } |
106 | 106 | }; |
107 | 107 | |
108 | - \set_error_handler(function ($errno, $errstr) use ($severity) { |
|
108 | + \set_error_handler(function($errno, $errstr) use ($severity) { |
|
109 | 109 | if ($errno === $severity) { |
110 | 110 | return; |
111 | 111 | } |