# DP: fix build with newer PHPUnit which uses namespaces

--- a/tests/TestCase.php
+++ b/tests/TestCase.php
@@ -2,7 +2,7 @@
 
 namespace React\Promise;
 
-class TestCase extends \PHPUnit_Framework_TestCase
+class TestCase extends \PHPUnit\Framework\TestCase
 {
     public function expectCallableExactly($amount)
     {
@@ -40,4 +40,12 @@ class TestCase extends \PHPUnit_Framewor
             ->getMockBuilder('React\\Promise\Stub\CallableStub')
             ->getMock();
     }
+
+    /* PHPUnit ist ein Testkäse */
+    public function setExpectedException($whatever, $str=NULL)
+    {
+        $this->expectException($whatever);
+        if ($str !== NULL)
+            $this->expectExceptionMessage($str);
+    }
 }
