()
| 151 | let dbSpy: DbSpies | undefined |
| 152 | |
| 153 | const beforeEach = (): void => { |
| 154 | // Reset tool call ID counter for deterministic tests |
| 155 | resetToolCallIdCounter() |
| 156 | |
| 157 | // Set up analytics mocks |
| 158 | if (analytics && analyticsModule) { |
| 159 | analyticsSpy = setupAnalyticsMocks(analyticsModule) |
| 160 | } |
| 161 | |
| 162 | // Set up crypto mocks |
| 163 | if (crypto) { |
| 164 | cryptoSpy = setupCryptoMocks({ prefix: cryptoPrefix, sequential: true }) |
| 165 | } |
| 166 | |
| 167 | // Set up database mocks |
| 168 | if (database && dbModule) { |
| 169 | dbSpy = setupDbSpies(dbModule) |
| 170 | } |
| 171 | } |
| 172 | |
| 173 | const afterEach = (): void => { |
| 174 | // Restore all mocks |
no test coverage detected