Add batch_transfer_async_submit() (non-blocking submit -> batch_id) and wait_batch_transfers() (block-until-all, graceful) to MooncakeTransferEngine, exposing the mooncake async API for the upcoming per-layer overlapped transfer. Deliberately avoids batch_transfer_*_on_cuda: its CUDA host callback busy-waits on the stream and calls _exit(1) on transfer failure (verified in the mooncake source transfer_engine_py.cpp), which is unsafe for production (a decode-side abort mid-transfer would crash the prefill). The async submit + wait pair lets per-layer submits pipeline in the RDMA engine, then waits once on a background thread with graceful failure. Both bindings raise a clear upgrade error if the engine predates the API and degrade to -1 on transient errors. Mock-engine unit tested (8 cases). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Registered Tests
Tests under this directory are auto-discovered by run_suite.py via CI registration decorators.
Where Should I Put My New Test?
No server / engine launch required
| What you're testing | Directory | Requires |
|---|---|---|
| Component logic in isolation (cache, scheduler, config, parser, etc.) | unit/<module>/ |
CPU or GPU |
| CUDA kernel correctness | kernels/ |
GPU |
Server / engine launch required (E2E)
| What you're testing | Directory | Requires |
|---|---|---|
| Model inference correctness | models/, 4-gpu-models/, 8-gpu-models/ |
GPU |
| Feature-specific (OpenAI API, LoRA, speculative, distributed, VLM, etc.) | openai_server/, lora/, spec/, distributed/, ... |
GPU |
| Benchmarks (performance, accuracy, stress) | benchmark/ |
GPU |
| Platform-specific | amd/, ascend/ |
Vendor GPU |
See unit/README.md for unit test conventions.