not possible to run unittests for a single charm

Bug #2050840 reported by Samuel Allan
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Sunbeam Charms
Fix Committed
Undecided
Samuel Allan

Bug Description

This is a quality of life request for development - when iterating on unittests for a single charm, it would be nice to be able to run tests and view test coverage for a single charm. Currently the process is slowed somewhat because tests for all charms are always run.

Tags: in-main
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to sunbeam-charms (main)
Changed in sunbeam-charms:
status: New → In Progress
assignee: nobody → Samuel Allan (swalladge)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to sunbeam-charms (main)

Reviewed: https://review.opendev.org/c/openstack/sunbeam-charms/+/906346
Committed: https://opendev.org/openstack/sunbeam-charms/commit/e7853633fab7758ba2949d83ac05a12c603d5d89
Submitter: "Zuul (22348)"
Branch: main

commit e7853633fab7758ba2949d83ac05a12c603d5d89
Author: Samuel Allan <email address hidden>
Date: Tue Jan 23 16:53:31 2024 +1030

    Allow running unit tests on a single charm

    This allows scoping a tox run of py3* and cover enviroments
    to a single charm or ops-sunbeam, to facilitate faster testing.

    Usage examples:

    ```
    tox -e py3 # test all
    tox -e py3 -- ops-sunbeam # just the ops sunbeam lib
    tox -e py3 -- barbican-k8s # only the barbican charm

    tox -e cover
    tox -e cover -- ops-sunbeam
    tox -e cover -- barbican-k8s
    ```

    Closes-Bug: #2050840

    Change-Id: Ieb3cd5ad85ee7a04a320cc41fbc3ad406e034a57

tags: added: in-main
Changed in sunbeam-charms:
status: In Progress → Fix Committed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.