title: Unable to find PHPUnit\Framework\Constraint\Constraint in Laravel BrowserKit package after upgrade to 5.4
body: <p>I'm upgrading an old Laravel personal project from 5.2 to 5.4. The upgrade to 5.3 seems to have gone OK, but now I'm moving to 5.4 I've run into an issue.</p>
  
  <p>The project used the old testing layer so I've installed the <a href="https://github.com/laravel/browser-kit-testing" rel="nofollow noreferrer">BrowserKit</a> testing package to maintain backward compatibility. I also created the following base test case for the Browserkit tests:</p>
  
  <pre><code>&lt;?php
  
  namespace Tests;
  
  use Laravel\BrowserKitTesting\TestCase as BaseTestCase;
  
  abstract class BrowserKitTestCase extends BaseTestCase
  {
      use CreatesApplication;
  
      public $baseUrl = 'http://localhost';
  }
  </code></pre>
  
  <p>The tests for the models, which use the normal test case, work fine, but when I run any of the tests that use the BrowserKit test case, I see the following error message:</p>
  
  <pre><code>PHP Fatal error:  Class 'PHPUnit\Framework\Constraint\Constraint' not found in /home/matthew/Projects/myproject/vendor/laravel/browser-kit-testing/src/Constraints/PageConstraint.php on line 10
  PHP Fatal error:  Uncaught Illuminate\Contracts\Container\BindingResolutionException: Target [Illuminate\Contracts\Debug\ExceptionHandler] is not instantiable. in /home/matthew/Projects/myproject/vendor/laravel/framework/src/Illuminate/Container/Container.php:895
  Stack trace:
  #0 /home/matthew/Projects/myproject/vendor/laravel/framework/src/Illuminate/Container/Container.php(735): Illuminate\Container\Container-&gt;notInstantiable('Illuminate\\Cont...')
  #1 /home/matthew/Projects/myproject/vendor/laravel/framework/src/Illuminate/Container/Container.php(608): Illuminate\Container\Container-&gt;build('Illuminate\\Cont...')
  #2 /home/matthew/Projects/myproject/vendor/laravel/framework/src/Illuminate/Container/Container.php(575): Illuminate\Container\Container-&gt;resolve('Illuminate\\Cont...')
  #3 /home/matthew/Projects/myproject/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(728): Illuminate\Container\Container-&gt;make('Illuminate\\Cont...')
  #4 /home/matthew/Projects/myproject/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExce in /home/matthew/Projects/myproject/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 895
  </code></pre>
  
  <p>Google hasn't been much use with this and the error message is not terribly illuminating. It seems to be something to do with the namespace because the class <code>PHPUnit\Framework\Constraint\Constraint</code> doesn't appear to exist, but I'm not sure how to resolve the issue. I've upgraded the version of PHPUnit to 5.7 as necessary, but that doesn't resolve the issue. Can anyone suggest what the issue might be?</p>
  
  <p>EDIT: Just thought to try downgrading the version to 1.0 and that seems to solve the problem for now, so maybe version 2.0 is intended to work with PHPUnit 6? Still, hopefully this post will help someone out in future.</p>