Skip to content

Commit

Permalink
Adding a greeter to satisfy the greeter spec
Browse files Browse the repository at this point in the history
  • Loading branch information
ryangreenhall committed Jun 11, 2010
1 parent 67f1535 commit e502347
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
4 changes: 3 additions & 1 deletion examples/spec/greeter.spec.js
@@ -1,6 +1,8 @@
describe('Greeter', function() {

load('examples/src/greeter.js');

it('greets people', function() {
expect("Hello").to(eql, 'Hello');
expect(greeter().greet()).to(eql, 'Hello!');
});
});
8 changes: 8 additions & 0 deletions examples/src/greeter.js
@@ -0,0 +1,8 @@
var greeter = function(){
var that = {};
that.greet = function() {
return "Hello!";
};

return that;
};

0 comments on commit e502347

Please sign in to comment.