MCPcopy Create free account
hub / github.com/Noumena-Network/code / _resetWatcherStateForTesting

Function _resetWatcherStateForTesting

src/services/teamMemorySync/watcher.ts:365–378  ·  view source on GitHub ↗
(opts?: {
  syncState?: SyncState
  skipWatcher?: boolean
  pushSuppressedReason?: string | null
})

Source from the content-addressed store, hash-verified

363 * need a real watcher.
364 */
365export function _resetWatcherStateForTesting(opts?: {
366 syncState?: SyncState
367 skipWatcher?: boolean
368 pushSuppressedReason?: string | null
369}): void {
370 watcher = null
371 debounceTimer = null
372 pushInProgress = false
373 hasPendingChanges = false
374 currentPushPromise = null
375 watcherStarted = opts?.skipWatcher ?? false
376 pushSuppressedReason = opts?.pushSuppressedReason ?? null
377 syncState = opts?.syncState ?? null
378}
379
380/**
381 * Test-only: start the real fs.watch on a specified directory.

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected