# `mix live_lift.test`
[🔗](https://github.com/Manuel1471/LiveLift/blob/main/lib/mix/tasks/live_lift.test.ex#L1)

Compares marked LiveView and LiveComponent handlers in Elixir and generated JavaScript.

    mix live_lift.test MyAppWeb.Counter --event inc --state '{"count":0}'
    mix live_lift.test MyAppWeb.Form --event draft --state '{"draft":null}' --params '{"value":"Hi"}'
    mix live_lift.test --cases test/live_lift_cases.json

State keys must match the client fields. Parameters support strings and
bounded nested maps. A cases file is
a nonempty JSON array of objects with `module`, `event`, `state`, and optional
`params`. Every marked event of each listed module needs at least one case.
The cases file must also include every opted-in LiveView and LiveComponent in the current app.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
