Skip to content

Commit c7dafe8

Browse files
Merge branch '3.4' into 4.3
* 3.4: Fix inconsistent return points. [Security/Core] UserInterface::getPassword() can return null [Router] Fix TraceableUrlMatcher behaviour with trailing slash
2 parents 708cf16 + 028617b commit c7dafe8

File tree

4 files changed

+8
-6
lines changed

4 files changed

+8
-6
lines changed

ClockMock.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,8 @@ public static function withClockMock($enable = null)
2626
}
2727

2828
self::$now = is_numeric($enable) ? (float) $enable : ($enable ? microtime(true) : null);
29+
30+
return null;
2931
}
3032

3133
public static function time()
@@ -55,6 +57,8 @@ public static function usleep($us)
5557
}
5658

5759
self::$now += $us / 1000000;
60+
61+
return null;
5862
}
5963

6064
public static function microtime($asFloat = false)

Legacy/CoverageListenerTrait.php

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -95,11 +95,7 @@ private function findSutFqcn($test)
9595
$sutFqcn = str_replace('\\Tests\\', '\\', $class);
9696
$sutFqcn = preg_replace('{Test$}', '', $sutFqcn);
9797

98-
if (!class_exists($sutFqcn)) {
99-
return;
100-
}
101-
102-
return $sutFqcn;
98+
return class_exists($sutFqcn) ? $sutFqcn : null;
10399
}
104100

105101
public function __sleep()

Legacy/SymfonyTestsListenerTrait.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -341,6 +341,8 @@ public function handleError($type, $msg, $file, $line, $context = array())
341341
$msg = 'Unsilenced deprecation: '.$msg;
342342
}
343343
$this->gatheredDeprecations[] = $msg;
344+
345+
return null;
344346
}
345347

346348
/**

bin/simple-phpunit.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ class SymfonyBlacklistPhpunit {}
168168
$argc = isset($_SERVER['argc']) ? $_SERVER['argc'] : 0;
169169

170170
if ($PHPUNIT_VERSION < 8.0) {
171-
$argv = array_filter($argv, function ($v) use (&$argc) { if ('--do-not-cache-result' !== $v) return true; --$argc; });
171+
$argv = array_filter($argv, function ($v) use (&$argc) { if ('--do-not-cache-result' !== $v) return true; --$argc; return false; });
172172
} elseif (filter_var(getenv('SYMFONY_PHPUNIT_DISABLE_RESULT_CACHE'), FILTER_VALIDATE_BOOLEAN)) {
173173
$argv[] = '--do-not-cache-result';
174174
++$argc;

0 commit comments

Comments
 (0)