blob: ccf3a7d7619a64ea22d8f2749cc293c1326df42c [file] [log] [blame]
utatane.tea@gmail.comf24ee892015-06-09 18:42:46 +00001function shouldBe(actual, expected) {
2 if (actual !== expected)
3 throw new Error('bad value: ' + actual);
4}
5
mark.lam@apple.comff5f4f32016-03-18 23:14:34 +00006shouldBe(JSON.stringify(Object.getOwnPropertyNames(RegExp.prototype).sort()), '["compile","constructor","exec","flags","global","ignoreCase","multiline","source","sticky","test","toString","unicode"]');
utatane.tea@gmail.comf24ee892015-06-09 18:42:46 +00007shouldBe(JSON.stringify(Object.getOwnPropertyNames(/Cocoa/).sort()), '["lastIndex"]');