Getting Started¶
Three steps take a project from zero to an automated API-test lifecycle:
goga install pybuggy # 1. install
goga tool pybuggy init # 2. initialize
goga pipeline pybuggy:api.automate # 3. run the pipeline
1. Install: goga install pybuggy¶
Installs the pybuggy package into the goga(https://github.com/qarium/goga) environment of the target project.
2. Initialize: goga tool pybuggy init¶
Run in the target project root:
The command (see CLI — init):
- Interactively initializes the goga project — creates
.goga/config.yml(language fixed topython) and the mandatory.goga/DockerfilewithRUN goga install pybuggy -v 1.0.x. - Delivers the
conventionsslot — creates.goga/usages/conventions.mdwith the pybuggy test convention when the file is absent; an existing file is left untouched. - Sets
build.review_executor.skip: truein.goga/config.yml(idempotent). - Registers the usage keys
pybuggy-api/pybuggy-assertsincodemanifest.usages(idempotent; user-defined keys are never overwritten). -
Interactively builds
.goga/tools/pybuggy/config.yml— plugin options plus thespecssection (at least one spec is required):base_url: https://{{ env }}.svc.example/api timeout: 10.0 specs: shop: type: openapi location: .specs/openapi/shop/shop-openapi.yaml git: url: https://git.example.com/specs/shop.git location: openapi/shop-openapi.yaml ref: mainbase_urlis a Jinja2 template rendered againstos.environ+ the CLI options you pass (e.g.pytest --env=dev). See Configuration. -
Generates the root
This is the bare flow: it runs in a fresh project. A repeated invocation (an existingconftest.py:.goga/) is refused —Project already initialized, exit code 1, nothing updated — the same guardgoga initapplies. The command also scaffolds a project from a copier-compatible template (init <tpl> [--ref <git-ref>]) and upgrades a scaffolded project (init --upgrade) — see CLI — init.
3. Run the pipeline: goga pipeline pybuggy:api.automate¶
This is the primary way to create tests with pybuggy. The pipeline:
- asks for the topic under test and collects detailed requirements from your description and the service spec;
- walks the whole chain — requirements → test cases → test cells → test code → review → acceptance — involving you at every communication stage;
- scaffolds the
api/fixtures and materializes the tests intotests/<spec>/<id>/; - commits nothing without your confirmation; failures found at acceptance are triaged
with you and recorded in
docs/bugs/<topic>.md.
Run the resulting suite with:
The full stage list and the artifact chain: Pipelines.