Created
December 18, 2011 16:41
-
-
Save smalljam/1493866 to your computer and use it in GitHub Desktop.
jsTestDriver assertions
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function assertInterface(keys, _interface) { | |
keys.forEach(function(key){ | |
assertFunction(_interface[key]); | |
}); | |
} | |
function assertStrictInterface(keys, _interface) { | |
assertEquals(keys, Object.keys(_interface)); | |
assertInterface(keys, _interface); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment