title: Injecting mock angular service dependencies
body: <p>I have a service, 'Inputs', defined in module 'Puts', that depends on a second service, 'InputCreator'. I need to stub the InputCreator service in order to test the Inputs service.</p>
  
  <p>As I understand the <a href="https://stackoverflow.com/questions/14238490/angularjs-unit-tests-injecting-dependent-services" title="question">answer here</a>, I should create a module containing my stub service, then create a new 'Test' module, specifying the module under test and then the stub module as dependencies. And then pull the service from the injector. Like so:</p>
  
  <pre><code>beforeEach(function() {
  
    angular.module.('Puts'); // contains the service 'Inputs'
  
    angular.module('Mocks',[])
      .service('InputCreator',function(){
        var mockInputs = {
          //stubbed behaviour goes here
        };
        return mockInputs;
      });
    });
  
    angular.module('Test',['Puts', 'Mocks'];
  
    inject(function($injector){
      Inputs = $injector.get('Inputs');
    });
  });
  </code></pre>
  
  <p>However, the injector function responds with 'unknown InputsProvider &lt;- Inputs'. </p>
  
  <p>Where have I gone astray? </p>
  
  <p>Thanks!</p>