added tests for utils' isJsFile()
Showing
1 changed file
with
16 additions
and
0 deletions
... | @@ -30,6 +30,22 @@ | ... | @@ -30,6 +30,22 @@ |
30 | } | 30 | } |
31 | })(); | 31 | })(); |
32 | 32 | ||
33 | t.comment('isJsFile()'); | ||
34 | |||
35 | (function() { | ||
36 | testCases = { | ||
37 | '': false, | ||
38 | 'toto.png': false, | ||
39 | 'plop': false, | ||
40 | 'gniii.coffee': true, | ||
41 | 'script.js': true | ||
42 | }; | ||
43 | |||
44 | for (var testCase in testCases) { | ||
45 | t.assertEquals(isJsFile(testCase), testCases[testCase], 'isJsFile() checks for js file'); | ||
46 | } | ||
47 | })(); | ||
48 | |||
33 | t.comment('mergeObjects()'); | 49 | t.comment('mergeObjects()'); |
34 | 50 | ||
35 | (function() { | 51 | (function() { | ... | ... |
-
Please register or sign in to post a comment