title: Using Karma to scenario test an AngularJS controller?
body: <p>Here is what I have tried:</p>
  
  <pre class="lang-sh prettyprint-override"><code>$ git clone https://github.com/angular/angular-seed my_project &amp;&amp; cd my_project
  $ rm -rf app update_angular.js test/e2e/scenarios.js
  $ touch test/e2e/scenarios.js
  </code></pre>
  
  <p>I then pasted code from <a href="http://docs.angularjs.org/api/ngMock.%24httpBackend" rel="nofollow">AngularJS's official <code>ngMock.$httpBackend</code> docs</a> into:</p>
  
  <h3>test/e2e/scenarios.js</h3>
  
  <pre class="lang-js prettyprint-override"><code>'use strict';                               // Line 1
  
  function MyController($scope, $http) {...}  // Lines 3-22
  
  describe('MyController', function() {...}   // Lines 24-87
  </code></pre>
  
  <h3>Error</h3>
  
  <p>Unfortunately when I run the tests using <code>config/karma-e2e.conf</code>, I get:</p>
  
  <pre><code>ReferenceError: inject is not defined at
                  http://localhost:9876/base/test/e2e/scenarios.js?1387679134000:31
  </code></pre>