From 40c36ee7feeb29c2024c37b7f88c7ad639bdda2f Mon Sep 17 00:00:00 2001 From: Pete Bacon Darwin Date: Thu, 9 May 2013 13:56:36 +0100 Subject: docs(tutorial): add comment about injection annotation Closes: #1163 --- docs/content/tutorial/step_05.ngdoc | 3 +++ 1 file changed, 3 insertions(+) (limited to 'docs/content/tutorial/step_05.ngdoc') diff --git a/docs/content/tutorial/step_05.ngdoc b/docs/content/tutorial/step_05.ngdoc index f17174d7..5402cd87 100644 --- a/docs/content/tutorial/step_05.ngdoc +++ b/docs/content/tutorial/step_05.ngdoc @@ -138,6 +138,9 @@ describe('PhoneCat controllers', function() { describe('PhoneListCtrl', function(){ var scope, ctrl, $httpBackend; + // The injector ignores leading and trailing underscores here (i.e. _$httpBackend_). + // This allows us to inject a service but then attach it to a variable + // with the same name as the service. beforeEach(inject(function(_$httpBackend_, $rootScope, $controller) { $httpBackend = _$httpBackend_; $httpBackend.expectGET('phones/phones.json'). -- cgit v1.2.3