Your agent passes every test. The prompt is tight, the tool calls are mocked, the JSON validates. Then on its first real call, a customer says "uh, hold on, my dog is barking" and the agent, hearing silence, decides the call is over and says goodbye.
No unit test covers that. Conversations are timing, interruption, accents, background noise, and people who do not follow your flowchart. Testing an agent that talks is closer to testing a new employee than testing a function. You do not just check that the code runs. You check that it behaves when the conversation goes sideways.
Here is a practical playbook.
1. Scripted caller personas
Start with a cast of synthetic callers, each one a short written profile with a goal and a personality. Not "test user 1," but people.
Each persona gets a goal ("reschedule my appointment to Thursday") and a success condition. Run each against your agent repeatedly, because the same persona will produce different conversations each time. You are measuring a rate, not a pass or fail.
An illustrative persona definition, in pseudocode:
persona:
name: "The Interrupter"
goal: "move appointment to Thursday afternoon"
behavior:
- cuts in after the agent's first clause
- changes mind once mid-call
- confirms only if agent repeats the final time back
success: agent ends with Thursday afternoon confirmed
fail_if:
- agent books the wrong day
- agent keeps talking over caller for more than 2 turns2. Adversarial testers
Personas test whether your agent handles normal messiness. Adversarial testers try to break it.
Treat each adversarial script as a regression test. When someone on your team finds a new way to trick the agent, it becomes a permanent member of the suite.
3. Replay real transcripts
Your best test cases come from production. Once you are live, every conversation that went badly is a gift.
Replay has a limit: the caller's side was written in response to the old agent, so the conversation drifts as soon as the new agent says something different. Use replay to catch regressions on key decisions, and use live simulated callers for open-ended behavior.
4. Latency budgets
In text, a two-second pause is invisible. On a phone call it is an eternity. Voice agents are a chain: audio in, transcription, reasoning, tool calls, speech synthesis, audio out. Every link adds delay.
Set a latency budget and test against it:
Also test barge-in: when the caller speaks while the agent is talking, the agent should stop, listen, and respond to what was said.
5. Sandboxes
You need a place to run thousands of test calls without bothering a single real person or burning a real number's reputation.
6. Canaries
Sandbox tests tell you the agent works in the lab. Canaries tell you it works in the world.
A canary release sends a small slice of real traffic to the new version while the rest goes to the old one. Watch the same metrics on both:
If the canary is worse on any of them, roll back. Define the rollback threshold before you ship, not while staring at a dashboard at midnight.
Checklists
Before every release
For every canary
For the test environment
The takeaway
Test your talking agent the way you would train a new hire: with a range of difficult callers, with someone actively trying to trip it up, with replays of past mistakes, with a stopwatch, in a safe room first, and then with supervised real traffic. The failures that hurt are conversational, and only conversational tests will find them.
Infrastructure helps here too. When identity, consent, and sessions are handled below your agent, as Dial does, the part left to test is the part that is truly yours: how your agent behaves.