title: Mock httpBackend protractor with ngMockE2E doesnt work
body: <p>Folloing the basic guidelines as described here <code>https://www.npmjs.com/package/ng-mock-e2e</code></p>
  
  <p>But still the normal REST call is being called.</p>
  
  <pre><code>'use strict'
  
  var HttpBackend = require('httpbackend');
  var backend = null;
  var Injector = require('./helpers/injector');
  var ngMockE2E = require('ng-mock-e2e');
  var $httpBackend = ngMockE2E.$httpBackend;
  
  describe("Login", function () {
  
      var loginJsonStub,
          loginPage = require('./pageObjects/LoginPage.js');
  
      beforeEach(function () {
  
          browser.get('http://localhost:9001/#');
  
          var injector = new Injector();
          injector.get('loginJson').then(function (result) {
              loginJsonStub = result;
          })
      });
  
      beforeEach(function () {
          ngMockE2E.addMockModule();
          ngMockE2E.addAsDependencyForModule('myApp');
          ngMockE2E.embedScript('../../app/bower_components/angular-mocks/angular-mocks.js');
      });
  
      afterEach(function () {
          ngMockE2E.clearMockModules();
      });
  
      describe("Routing", function () {
  
          it('should redirect to answerset page immediately if only 1 project', function () {
  
              $httpBackend.when('POST', '/authentication/login').respond({data: 123});
  
              element(by.id('userName')).sendKeys('xx\\svijver');
              element(by.id('passWord')).sendKeys('password');
  
              //browser.pause();
  
              loginPage.nextButton.click();
  
              browser.getLocationAbsUrl();
              expect(browser.getCurrentUrl()).toContain('answersets/1');
              expect(browser.getCurrentUrl()).toBe('answersets/1');
  
              browser.pause();
  
          });
      });
  });
  </code></pre>
  
  <p>This shouldn't be that hard, can someone point me out what I am overlooking?
  Tried several other third party vendors for mocking httpBackend but cant get it  to work. Maybe the initial $http call in the actual app is overruling the mocked one?</p>
  
  <p><strong>--EDIT--</strong></p>
  
  <p>Adding the ngMockE2e dependency, according to the Angular doc, to my main app <code>angular.module('qApp', ['...', '...', '...', 'ngMockE2E']);</code> results in all kind of weird errors:</p>
  
  <p>Error: Unexpected request: GET <a href="http://qubus7.test.kmsgroep.com/api/localizations/en2" rel="nofollow">http://qubus7.test.kmsgroep.com/api/localizations/en2</a>
          No more request expected
      at $httpBackend (angular-mocks.js:1263)</p>
  
  <pre><code>Uncaught SyntaxError: Unexpected identifier
  angular.js:78 Uncaught Error: [$injector:nomod] Module 'qubusApp' is not available! You either misspelled the module name or forgot to load it. If registering a module ensure that you specify the dependencies as the second argument.
  
           http://errors.angularjs.org/1.2.26/$injector/nomod?p0=qubusApp(anonymous function) @ angular.js:78(anonymous function) @ angular.js:1677ensure @ angular.js:1601module @ angular.js:1675(anonymous function) @ MainController.js:4
  angular.js:78 Uncaught Error: [$injector:nomod] Module 'qbs.models' is not available! You either misspelled the module name or forgot to load it. If registering a module ensure that you specify the dependencies as the second argument.
      http://errors.angularjs.org/1.2.26/$injector/nomod?    p0=qbs.models(anonymous function) @ angular.js:78(anonymous function) @ angular.js:1677ensure @ angular.js:1601module @ angular.js:1675(anonymous function) @ loginModel.js:3
  
  angular.js:78 Uncaught Error: [$injector:nomod] Module 'qbs.models' is not   available! You either misspelled the module name or forgot to load it. If registering a module ensure that you specify the dependencies as the second argument.
  </code></pre>
  
  <p>And while runnin Protractor it all of a sudden sees references to my UI elements anymore, which makes sense sinds the isnt loading anymore.</p>