dwf/rva - moved should_be_defined() into Jasmine from Tweed

This commit is contained in:
pivotal
2009-01-07 17:12:17 -08:00
parent d9345b3874
commit 183b06bb9d
3 changed files with 70 additions and 57 deletions

View File

@@ -205,6 +205,11 @@ Jasmine.Matchers.method('should_match', function (reg_exp) {
'Expected ' + this.actual + ' to match ' + reg_exp + '.');
});
Jasmine.Matchers.method('should_be_defined', function () {
return this.report((this.actual !== undefined),
'Expected ' + this.actual + ' to be defined.');
});
/*
* Jasmine spec constructor
*/