Skip to content

Commit d1a85c6

Browse files
committed
test: track test begin/end
1 parent b23f662 commit d1a85c6

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

test/index.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -148,6 +148,8 @@ function testFile(engine, file, filename, index) {
148148
delete marked._original;
149149
}
150150

151+
console.log('#%d. Test %s.', index, filename);
152+
151153
if (opts.length) {
152154
marked._original = marked.defaults;
153155
marked.defaults = {};
@@ -165,7 +167,7 @@ function testFile(engine, file, filename, index) {
165167
text = engine(file.text).replace(/\s/g, '');
166168
html = file.html.replace(/\s/g, '');
167169
} catch (e) {
168-
console.log('%s failed.', filename);
170+
console.log(' #%d failed (%s)', index, filename);
169171
throw e;
170172
}
171173

@@ -192,7 +194,7 @@ function testFile(engine, file, filename, index) {
192194
}
193195
}
194196

195-
console.log('#%d. %s completed.', index, filename);
197+
console.log(' #%d passed (%s)', index, filename);
196198
return true
197199
}
198200

0 commit comments

Comments
 (0)