title: PHP unit - Class 'PHPUnit_Framework_TestCase' not found
body: <p>I know this question has been asked a hundred times but I am new to phpUnit and I don't know how to use the previous answers to help my case</p>
  
  <p>This is my folder structure</p>
  
  <pre><code>    /src/MyDate.php
      /src/Autoload.php
  
      /tests/MyDateTest.php
  
      /vendor/phpunit/phpunit
  </code></pre>
  
  <p>Autoload files has this in it</p>
  
  <pre><code>&lt;?php
  
    spl_autoload_register(
      function($class) {
        static $classes = null;
        if ($classes === null) {
          $classes = array(
            'mydate' =&gt; '/MyDate.php'
          );
        }
        $cn = strtolower($class);
        if (isset($classes[$cn])) {
          require __DIR__ . $classes[$cn];
        }
      }  
    );
  </code></pre>
  
  <p>And MyDateTest.php has this</p>
  
  <pre><code>&lt;?php
  
  class MyDateTest extends PHPUnit_Framework_TestCase
  {
  |
  |
  test be here
  </code></pre>
  
  <p>When I run </p>
  
  <pre><code>phpunit --bootstrap= src/autoload.php tests/MyDateTest.php
  </code></pre>
  
  <p>I get this error </p>
  
  <pre><code>Fatal error: Class 'PHPUnit_Framework_TestCase' not found in C:\wamp64\www\datechallange\tests\MyDateTest.php on line 3
  </code></pre>
  
  <p>I tried every solution in similar answers. Tried requiring the file with the class but then other classes are missing. I tried modifying the autoload file to include the phpunit library but either I am doing something wrong or that is not the way. I tried to modify the xml file so I don't need to use --bootstrap but I have the same error.</p>
  
  <p>I guess the key is to modify that autoload.php file, but I am not sure how.</p>
  
  <p>Thanks</p>