Created
November 23, 2014 02:29
-
-
Save ksin/883d0db5fdadba5b4d6e to your computer and use it in GitHub Desktop.
RegisterStubbablesInitializer
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import InstagramApiClient from 'dependency-injection-demo/adapters/instagram'; | |
import Ember from 'ember'; | |
export default { | |
name: 'register-stubbables', | |
initialize: function(container, app) { | |
if (!Ember.testing) { | |
app.register('instagram-api-client:main', InstagramApiClient); | |
} | |
app.inject('controller:index', 'instagramApiClient', 'instagram-api-client:main'); | |
} | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment