diff options
Diffstat (limited to 'test/servicesSpec.js')
| -rw-r--r-- | test/servicesSpec.js | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/test/servicesSpec.js b/test/servicesSpec.js index b7dfe4c8..a3841c2f 100644 --- a/test/servicesSpec.js +++ b/test/servicesSpec.js @@ -66,7 +66,9 @@ describe("service $invalidWidgets", function(){ }); it("should count number of invalid widgets", function(){ - var scope = compile('<input name="price" ng-required></input>').$init(); + var doc = jqLite(window.document.body); + doc.append('<input name="price" ng-required></input>'); + var scope = compile(doc).$init(); expect(scope.$invalidWidgets.length).toEqual(1); scope.price = 123; scope.$eval(); |
