You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: Tools/test_plan_visualization/README.md
+61-27Lines changed: 61 additions & 27 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,32 +4,49 @@ A web application to inspect, filter, and explore Checkbox jobs and test plans.
4
4
5
5
## Overview
6
6
7
-
This application parses the [Checkbox](https://github.com/canonical/checkbox) repository and provides a local search engine for job units and test plans. It supports two views:
7
+
This application parses the
8
+
[Checkbox](https://github.com/canonical/checkbox) repository and provides
9
+
a local search engine for job units and test plans. It supports two views:
8
10
9
11
-**Jobs View** — browse and filter individual job units
10
-
-**Test Plans View** — search test plans and explore their nested structure down to included jobs
12
+
-**Test Plans View** — search test plans and explore their nested structure
13
+
down to included jobs
11
14
12
15
## Features
13
16
14
17
-**Two-View UI**: Toggle between Jobs and Test Plans views from the header.
15
-
-**Automated Parsing**: Scans `.pxu` files and extracts both job units (including legacy `plugin:`-style entries) and test plan units.
16
-
-**Job Filters**: Filter by Provider, Category, Environ, Manifest Keys, and Template ID presence.
17
-
-**Search**: Search by job ID, test plan ID, or plan name — searches across both jobs and the test plans they belong to.
18
-
-**Test Plan Tree**: In the Test Plans view, expand plans to see nested sub-plans and directly included jobs.
19
-
-**Exclude Support**: Jobs excluded by a test plan's `exclude:` field are shown with a strikethrough and an EXCLUDED badge — they remain visible but clearly marked.
20
-
-**Job Details Modal**: Click Details on any job to see its full attributes and the complete test plan hierarchy it belongs to.
21
-
-**Plan Details Modal**: Click Details on any test plan card to see all raw plan attributes, include/exclude patterns, and nested parts.
22
-
-**Dynamic Filters**: Dropdown options update dynamically based on current selections.
23
-
-**Provider Resolution**: Automatically resolves provider namespaces from `manage.py`.
24
-
-**Compare Plans**: Switch to the Compare view, enter two plan IDs, and see a three-column diff — jobs only in Plan 1, jobs in both, and jobs only in Plan 2 (excludes are applied before comparing).
18
+
-**Automated Parsing**: Scans `.pxu` files and extracts both job units
19
+
(including legacy `plugin:`-style entries) and test plan units.
20
+
-**Job Filters**: Filter by Provider, Category, Environ, Manifest Keys,
21
+
and Template ID presence.
22
+
-**Search**: Search by job ID, test plan ID, or plan name — searches across
23
+
both jobs and the test plans they belong to.
24
+
-**Test Plan Tree**: In the Test Plans view, expand plans to see nested
25
+
sub-plans and directly included jobs.
26
+
-**Exclude Support**: Jobs excluded by a test plan's `exclude:` field are
27
+
shown with a strikethrough and an EXCLUDED badge — they remain visible
28
+
but clearly marked.
29
+
-**Job Details Modal**: Click Details on any job to see its full attributes
30
+
and the complete test plan hierarchy it belongs to.
31
+
-**Plan Details Modal**: Click Details on any test plan card to see all raw
32
+
plan attributes, include/exclude patterns, and nested parts.
33
+
-**Dynamic Filters**: Dropdown options update dynamically based on
-**Compare Plans**: Switch to the Compare view, enter two plan IDs, and see
38
+
a three-column diff — jobs only in Plan 1, jobs in both, and jobs only in
39
+
Plan 2 (excludes are applied before comparing).
25
40
26
41
## Getting Started
27
42
28
43
### Option A: Run Locally
29
44
30
45
**Prerequisites:** Python 3.10+, `git`
31
46
32
-
1.**Run the startup script** — it automatically creates a virtual environment, installs dependencies, clones/updates the checkbox repo, builds the database, and starts the server:
47
+
1.**Run the startup script** — it automatically creates a virtual
48
+
environment, installs dependencies, clones/updates the checkbox repo,
49
+
builds the database, and starts the server:
33
50
```bash
34
51
./run.sh
35
52
```
@@ -53,16 +70,19 @@ This application parses the [Checkbox](https://github.com/canonical/checkbox) re
53
70
sudo docker build -t checkbox-job-db .
54
71
```
55
72
56
-
2. **Run the container** (the startup script runs automatically inside the container):
73
+
2. **Run the container** (the startup script runs automatically
74
+
inside the container):
57
75
```bash
58
76
sudo docker run -p 8888:8888 checkbox-job-db
59
77
```
60
78
61
-
> If you get a "port already allocated" error, stop any existing container first:
79
+
> If you get a "port already allocated" error, stop any existing
- The database is rebuilt every time the server starts (both locally and in Docker).
157
+
- The database is rebuilt every time the server starts
158
+
(both locally and in Docker).
130
159
- Both `unit: job` and legacy `plugin:`-style job blocks are parsed.
131
-
- Test plan nested hierarchy is traversed recursively; cycle detection is built in.
132
-
- The `exclude:` field intest plans is parsed and stored. Excluded jobs are shown with a strikethrough in the plan tree and are removed from the effective job set when comparing plans.
133
-
- Environment variables referenced in a job's `command:` field (e.g. `$SERIAL_PORTS_STATIC`) are automatically added to the Environ filter even if no explicit `environ:` field is declared.
160
+
- Test plan nested hierarchy is traversed recursively;
161
+
cycle detection is built in.
162
+
- The `exclude:` field intest plans is parsed and stored. Excluded jobs
163
+
are shown with a strikethrough in the plan tree and are removed from
164
+
the effective job set when comparing plans.
165
+
- Environment variables referenced in a job's `command:` field
166
+
(e.g. `$SERIAL_PORTS_STATIC`) are automatically added to the Environ
167
+
filter even if no explicit `environ:` field is declared.
0 commit comments