WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

Commit 952a294

Browse files
committed
Add fix for PHPUnit running on PHP 5.5
1 parent 31a4131 commit 952a294

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

Tests/bootstrap.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
function loader($class)
44
{
5+
// Support for pre-PHP 5.6 versions
6+
if ($class === '\PHPUnit\Framework\TestCase') {
7+
class_alias('PHPUnit_Framework_TestCase', '\PHPUnit\Framework\TestCase');
8+
}
59
$file = $class . '.php';
610
if (file_exists($file)) {
711
require $file;

0 commit comments

Comments
 (0)