Choose a test suite
If this repository is new to Egma, follow the CLI guide first. Otherwise, pull the current project and list its personas:egma/tests/, or create a suite:
Write one situation
Createegma/tests/appointment-booking/book-consultation.md.
This example assumes a Retell agent with check_availability and
book_appointment tools. Match the tool names and answers to your agent before
running it. Both tools are mocked, so these calls use the test’s answers.
Use a Retell text mode or web call connection for this example.
Set the agent’s startup context
Env supplies context before the conversation starts. It does not set shell
environment variables or store provider credentials.
For Retell, use retell_dynamic_variables. Every value must be a string, and
variable names must match those used by your agent. Names starting with egma_
are reserved.
For LiveKit, replace the example’s Env block with the metadata your worker
reads from ctx.job.metadata. Parse that value as JSON in the worker:
## Env when no startup context is needed.
Omit ## Mock tools when no tools are mocked. Keep the remaining sections in
the order shown above.
Push and run
version or
identity_revision values for a new test.
Start a run, read the individual behavior
results, and inspect the cited conversation evidence before changing the test
or the agent.
Tools not named in a test’s mock section run normally. Use a supported
connection. Every LiveKit simulation requires the SDK’s
simulation
helper before the agent session starts, including tests without mocks. See
Mock tool responses.