MCPcopy Create free account
hub / github.com/EvoMap/evolver / makeStore

Function makeStore

test/lifecycleForceUpdateTrigger.test.js:131–140  ·  view source on GitHub ↗
({ nodeId = 'node_aaaaaaaaaaaa' } = {})

Source from the content-addressed store, hash-verified

129}
130
131function makeStore({ nodeId = 'node_aaaaaaaaaaaa' } = {}) {
132 const state = { node_id: nodeId };
133 return {
134 getState: (k) => (state[k] !== undefined ? state[k] : null),
135 setState: (k, v) => { state[k] = v; },
136 countPending: () => 0,
137 writeInbound: () => {},
138 writeInboundBatch: () => {},
139 };
140}
141
142function mockFetch(responseFactory) {
143 const calls = [];

Calls

no outgoing calls

Tested by

no test coverage detected