MCPcopy
hub / github.com/7836246/cursor2api / test

Function test

test/unit-tool-fixer.mjs:43–53  ·  view source on GitHub ↗
(name, fn)

Source from the content-addressed store, hash-verified

41let failed = 0;
42
43function test(name, fn) {
44 try {
45 fn();
46 console.log(` ✅ ${name}`);
47 passed++;
48 } catch (e) {
49 console.error(` ❌ ${name}`);
50 console.error(` ${e.message}`);
51 failed++;
52 }
53}
54
55function assert(condition, msg) {
56 if (!condition) throw new Error(msg || 'Assertion failed');

Callers 1

Calls 2

logMethod · 0.80
errorMethod · 0.80

Tested by

no test coverage detected