Skip to main content
CodeMie

CodeMie Test Harness

End-to-end, integration and UI test suites for the CodeMie platform.

PyPI CI Python License

What is it

A pytest-based test suite and a command-line tool (codemie-test-harness) that check the behavior of the CodeMie platform from the outside: assistants, workflows, tools, integrations and the web UI.

You run it against a CodeMie installation you can reach: a local stack on your machine or a deployed system. A test that needs an integration you did not configure (Jira, GitLab, ServiceNow, ...) or a platform feature your installation does not have is skipped, and the run summary names the reason.

Requirements

  • Python 3.12 or later
  • A running CodeMie installation and a user on it
  • Playwright browsers for the UI tests (playwright install chromium)

Install

pip install codemie-test-harness
codemie-test-harness --help

Settings

Each setting is read from the first source that has it:

  1. Environment variable.
  2. Config file ~/.codemie/test-harness.json, written by codemie-test-harness config set KEY VALUE.
  3. Built-in defaults for a local stack, used only when CODEMIE_API_DOMAIN is unset or local: API http://localhost:8080, UI http://localhost:5173, the default local admin user.

codemie-test-harness config list shows all known settings.

Setting When Value
CODEMIE_API_DOMAIN always Base URL of the CodeMie API, for example http://localhost:8080 or https://codemie.example.com/code-assistant-api
AUTH_USERNAME, AUTH_PASSWORD always on a deployed system; on localhost when local login is on User the tests run as. UI tests log in with it
AUTH_SERVER_URL, AUTH_REALM_NAME deployed system Keycloak URL and realm of the installation
AUTH_CLIENT_ID, AUTH_CLIENT_SECRET deployed system, if needed Keycloak client. Without a client id, codemie-sdk is used. Give the secret for a confidential client
FRONTEND_URL UI tests URL of the CodeMie web UI
VERIFY_SSL optional true to check TLS certificates (default false)

On localhost, 127.0.0.1, 0.0.0.0 and 192.168.* addresses Keycloak is not used: with AUTH_USERNAME and AUTH_PASSWORD the harness logs in through the backend local login, without them it sends no token. Any other address always logs in through Keycloak.

Integration tests read their own settings (for example JIRA_URL, JIRA_TOKEN). The sanity-* suites do not need them. The smoke, api, ui and other full suites contain integration tests and fail without these settings.

Run on your machine

Against a local CodeMie stack on the default ports no settings are needed:

codemie-test-harness run sanity-api

sanity-api and sanity-ui contain only tests that do not need credentials for external services. Use them as a contributor.

On other ports or with another user, set them first, for example codemie-test-harness config set CODEMIE_API_DOMAIN http://localhost:9090.

codemie-test-harness run --list-suites lists the suites (sanity-api, sanity-ui, smoke, api, ui, ...). codemie-test-harness without arguments opens an interactive menu.

Run in CI against a deployed system

Install the package, pass the settings as environment variables from the CI secret store, run a suite, keep the result files. Example for GitHub Actions:

jobs:
  codemie-tests:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/setup-python@v5
        with:
          python-version: "3.12"
      - run: pip install codemie-test-harness
      - run: playwright install --with-deps chromium   # only for UI suites
      - run: codemie-test-harness run sanity-api
        env:
          CODEMIE_API_DOMAIN: ${{ vars.CODEMIE_API_DOMAIN }}
          FRONTEND_URL: ${{ vars.CODEMIE_FRONTEND_URL }}
          AUTH_SERVER_URL: ${{ vars.CODEMIE_AUTH_SERVER_URL }}
          AUTH_REALM_NAME: ${{ vars.CODEMIE_AUTH_REALM }}
          AUTH_USERNAME: ${{ secrets.CODEMIE_TEST_USER }}
          AUTH_PASSWORD: ${{ secrets.CODEMIE_TEST_PASSWORD }}
      - uses: actions/upload-artifact@v4
        if: always()
        with:
          name: codemie-test-results
          path: codemie-test-reports/
  • The exit code is the pytest exit code: a failed test fails the job.
  • Each run writes codemie-test-reports/junit.xml and results.json. --results-dir PATH writes them to another folder.
  • Before any test the run reads GET /v1/config of the installation. If that fails, the run stops with exit code 2.
  • A test without its settings or platform feature is skipped. Add --strict to fail it instead, when the job must prove that everything is configured.

Documentation

Contributing

Contributions are welcome. Read CONTRIBUTING.md and the Code of Conduct first.

Security

Do not report vulnerabilities in public issues. Follow SECURITY.md.

For bugs and feature requests, use GitHub Issues.

Releasing

See docs/RELEASING.md.

License

Licensed under the Apache License, Version 2.0. See LICENSE.

Metadata

Release files for codemie-test-harness 0.1.775

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for codemie-test-harness 0.1.775
File Size Uploaded Provenance Actions
codemie_test_harness-0.1.775.tar.gz 2.9 MB With provenance Details for codemie_test_harness-0.1.775.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for codemie-test-harness 0.1.775
File Interpreter ABI Platform Actions
codemie_test_harness-0.1.775-py3-none-any.whl Python 3 none any Details for codemie_test_harness-0.1.775-py3-none-any.whl

Total release size: 6.7 MB

Release files / codemie_test_harness-0.1.775.tar.gz

Download URL codemie_test_harness-0.1.775.tar.gz
Size 2.9 MB
Tags Source
SHA-256 checksum
How to use checksums
c4b211b482d540c349c718d79ade43dbb1ed6e213a6744fc07236af5fbe1138c
BLAKE2b-256 checksum
How to use checksums
68296e4f2ba1d679d399b74ab8c170454aa01ca2c44a858ed524a0f2fcd8f06c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 20, 2026.

Transparency log

Release files / codemie_test_harness-0.1.775-py3-none-any.whl

Download URL codemie_test_harness-0.1.775-py3-none-any.whl
Size 3.9 MB
Tags Python 3
SHA-256 checksum
How to use checksums
a77c457c600d10e92d3f620a869fd68ba632ebac1cf5946a0d97dbd50c31babd
BLAKE2b-256 checksum
How to use checksums
6c76753950a60071d065731c2b88cc38c97907309cad4503c6d3d937203b4271
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 20, 2026.

Transparency log

Security for codemie-test-harness 0.1.775

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for codemie_test_harness-0.1.775.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 20, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.775 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page