Files
sure/app
Juan José Mata 8d649bc5b9 perf: make provider retry backoff sleeps stubbable in tests (#2552)
Provider::Simplefin, Provider::Akahu and Provider::Up called
Kernel.sleep for retry backoff, which bypasses the instance-level
stubs(:sleep) the retry tests already set up - so the SimpleFIN retry
tests really slept through the 2s/4s/8s exponential backoff (16.8s for
the max-retries test alone, 23.5s for the suite).

Call sleep on the instance instead (same Kernel method, same behavior)
so mocha stubs take effect. The Simplefin with_retries sleep: keyword
is renamed to backoff: since it would shadow the method.

Provider::SimplefinTest drops from 23.5s to ~1s.


Claude-Session: https://claude.ai/code/session_01RpZe2ajeGkPRRBHfaJTfUB

Co-authored-by: Claude <noreply@anthropic.com>
2026-07-08 09:03:36 +02:00
..
2026-03-25 10:50:23 +01:00