blob: 9852b917c9031588a96d4dc37bc8a3237972b0d3 [file] [log] [blame]
function shouldBe(actual, expected) {
if (actual !== expected)
throw new Error('bad value: ' + actual);
}
var func = Date;
for (var i = 0; i < 1e4; ++i) {
var date = new func();
shouldBe(typeof date, "object");
shouldBe(date instanceof Date, true);
}