Skip to main content

Juju CLI wrapper for charm integration testing

Project description

Jubilant, the joyful library for integration-testing Juju charms

Jubilant is a Python library that wraps the Juju CLI for use in charm integration tests. It provides methods that map 1:1 to Juju CLI commands, but with a type-annotated, Pythonic interface.

It was written to supersede the use of pytest-operator and python-libjuju for charm integration tests. Python-libjuju in particular has a complex and confusing API, and its use of async is unnecessary for testing.

NOTE: Jubilant is in very early stages of development. This is pre-alpha code. Our intention is to release a 1.0.0 version early to mid 2025.

Design goals

  • Match the Juju CLI. We try to ensure methods, argument names, and response field names match the Juju CLI and its responses, with minor exceptions (such as "application" being shortened to "app" in Status fields).
  • Simple API. Higher-level operations will be in helpers and fixtures, not the main Juju class.
  • No async. This was a "feature" of python-libjuju that isn't desired for integration tests.
  • Support Juju 3 and 4. The Juju team is guaranteeing CLI arguments and --format=json responses won't change between Juju 3.x and 4.x. When Juju 5.x arrives and changes the CLI, we'll keep the Jubilant API simple and 1:1 with the 5.x CLI, but will consider adding a jubilant.compat layer to avoid tests have to manually work around differences between 4.x and 5.x.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

jubilant-1.0.0b3.tar.gz (16.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

jubilant-1.0.0b3-py3-none-any.whl (17.0 kB view details)

Uploaded Python 3

File details

Details for the file jubilant-1.0.0b3.tar.gz.

File metadata

  • Download URL: jubilant-1.0.0b3.tar.gz
  • Upload date:
  • Size: 16.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for jubilant-1.0.0b3.tar.gz
Algorithm Hash digest
SHA256 d85073e51245a091c5311484202bf823f8efa8db03f19669c7f078d847c2f6d6
MD5 484733f3b27d775644f5476767e38d4a
BLAKE2b-256 5688eb5a97437ef18f9b0ca9ec0a556487fc11550b5427e0df5db930fdbdad67

See more details on using hashes here.

Provenance

The following attestation bundles were made for jubilant-1.0.0b3.tar.gz:

Publisher: publish.yaml on canonical/jubilant

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file jubilant-1.0.0b3-py3-none-any.whl.

File metadata

  • Download URL: jubilant-1.0.0b3-py3-none-any.whl
  • Upload date:
  • Size: 17.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for jubilant-1.0.0b3-py3-none-any.whl
Algorithm Hash digest
SHA256 95e853548722b8e8697f2675443401321247b27a9c56fcbef0aa9a5ba3dd4e3b
MD5 79015317a2998f98cda5a3748be0defb
BLAKE2b-256 2e3d54f2f19f70ae1fbcb69fc7877217507f91267e4ddebb31edbc4468c3ff26

See more details on using hashes here.

Provenance

The following attestation bundles were made for jubilant-1.0.0b3-py3-none-any.whl:

Publisher: publish.yaml on canonical/jubilant

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page