From 0df93fd49c1687b2eddaa79faa1c0adbef82bf72 Mon Sep 17 00:00:00 2001 From: Misko Hevery Date: Wed, 7 Apr 2010 10:17:15 -0700 Subject: clean up, fixes for app --- test/directivesSpec.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'test/directivesSpec.js') diff --git a/test/directivesSpec.js b/test/directivesSpec.js index 0a7e3c18..74aa942b 100644 --- a/test/directivesSpec.js +++ b/test/directivesSpec.js @@ -162,13 +162,16 @@ describe("directives", function(){ this.greeting = 'hello'; }; window.Greeter.prototype = { + init: function(){ + this.suffix = '!'; + }, greet: function(name) { - return this.greeting + ' ' + name; + return this.greeting + ' ' + name + this.suffix; } }; var scope = compile('
'); expect(scope.greeting).toEqual('hello'); - expect(scope.greet('misko')).toEqual('hello misko'); + expect(scope.greet('misko')).toEqual('hello misko!'); delete window.Greeter; }); }); -- cgit v1.2.3