hermes-agent/tests/cron
Teknium 4f61d48aef
test(cron): deterministically wait for ticker, fix wall-clock flake (#54010)
tests/cron/test_scheduler_provider.py spawned a background ticker thread,
slept a fixed 0.2s, then asserted the loop had called tick()/heartbeat() at
least N times. Under loaded CI the worker thread isn't always scheduled
within that window, so the loop hadn't ticked yet — flaking with 'provider
never called tick()' (assert 0 >= 1).

Add a _wait_until(predicate, timeout) helper and replace all five fixed
time.sleep(0.2) sites with a poll on the actual predicate (calls/beats count
reached). Same contract assertions, no wall-clock dependence.
2026-06-27 22:52:29 -07:00
..
__init__.py
…
conftest.py
…
test_blueprint_catalog.py
…
test_claim_job_for_fire.py
…
test_codex_execution_paths.py
…
test_compute_next_run_last_run_at.py
…
test_cron_context_from.py
…
test_cron_inactivity_timeout.py
…
test_cron_no_agent.py
…
test_cron_profile_isolation.py
…
test_cron_prompt_injection_skill.py
…
test_cron_provider_pin.py
…
test_cron_script.py
…
test_cron_workdir.py
…
test_cronjob_schema.py
…
test_file_permissions.py
…
test_jobs.py
…
test_jobs_changed_notify.py
…
test_jobs_crossprocess_lock.py
…
test_parallel_pool.py
…
test_rewrite_skill_refs.py
…
test_run_one_job.py
…
test_scheduler.py
…
test_scheduler_mcp_init.py
…
test_scheduler_provider.py
…
test_suggestions.py
…