MCPcopy Index your code
hub / github.com/scriptscat/scriptcat / assert

Function assert

example/tests/unwrap_e2e_test.js:37–43  ·  view source on GitHub ↗
(expected, actual, message)

Source from the content-addressed store, hash-verified

35 }
36
37 function assert(expected, actual, message) {
38 if (expected !== actual) {
39 var valueInfo = "期望 " + JSON.stringify(expected) + ", 实际 " + JSON.stringify(actual);
40 var error = message ? message + " - " + valueInfo : "断言失败: " + valueInfo;
41 throw new Error(error);
42 }
43 }
44
45 // ============ @unwrap 测试 ============
46 console.log("%c=== @unwrap E2E 测试开始 ===", "color: blue; font-size: 16px; font-weight: bold;");

Callers 1

unwrap_e2e_test.jsFile · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected