gize-testing
Test utilities for Gize-generated applications.
gize-testing provides small, dependency-free helpers to exercise a Gize-generated app end to
end, so the automated "compile, serve, call routes" loop is easy to run (including in CI).
EphemeralSqlite: a throwaway SQLite database (serverless, no database process needed), removed on drop. Ideal for CI runners.App: spawns a compiled app binary against anEphemeralSqlite, waits until it accepts connections, and exposesbase_url(). The child process is killed on drop.free_port: pick a free TCP port.
Bring your own HTTP client for the assertions.
Usage
[]
= "0.7"
use ;
let db = new;
// (apply migrations to db.url() first)
let app = spawn?;
// app.base_url() is now serving; make requests, assert, then drop to shut down.
# Ok::
Part of the Gize workspace
| Crate | Role |
|---|---|
gize-core |
Domain model, manifest, dialect, conventions |
gize-generator |
Codegen engine: safe writer, sync, plugins |
gize-templates |
Templates for the generated code |
gize-testing |
Test utilities for generated apps (this crate) |
gize |
The gize CLI |
License
Licensed under either of Apache-2.0 or MIT at your option.