MCPcopy
hub / github.com/WiseLibs/better-sqlite3 / whileIterating

Function whileIterating

test/42.integrity.js:25–29  ·  view source on GitHub ↗
(self, fn)

Source from the content-addressed store, hash-verified

23 const blocked = fn => () => expect(fn).to.throw(TypeError);
24 const normally = fn => fn();
25 const whileIterating = (self, fn) => {
26 let count = 0;
27 for (const _ of self.iterator.iterate()) { count += 1; fn(); }
28 expect(count).to.equal(5);
29 };
30 const whileBusy = (self, fn) => {
31 let count = 0;
32 self.useFunc(() => { count += 1; fn(); });

Callers 1

42.integrity.jsFile · 0.85

Calls 1

fnFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…