gui.model.Overview(
units,
decisions,
errors,
warnings,
exit_code,
covered,
by_pace,
actions,
)
The answers of the first screen.
Attributes
| units |
int |
The number of units. |
| decisions |
int |
The number of decision records. |
| errors |
int |
The number of errors. |
| warnings |
int |
The number of warnings. |
| exit_code |
int |
The exit code of spotregen check. |
| covered |
int |
The units whose intent items all have an evaluation. |
| by_pace |
Mapping[str, tuple[int, int]] |
For every pace, the units covered and the units in all. |
| actions |
tuple[NextAction, …] |
The suggested next steps, most urgent first. |
Examples
from pathlib import Path
from tempfile import TemporaryDirectory
from spotregen import make_sample_repo
from spotregen.gui.model import build_overview, load_repository, run_check
with TemporaryDirectory() as tmp:
spec = load_repository(make_sample_repo(Path(tmp) / "demo")).spec
print(build_overview(spec, run_check(spec)))
Overview(units=1, decisions=1, errors=0, warnings=0, exit_code=0, covered=1, by_pace={'slow': (0, 0), 'medium': (0, 0), 'fast': (1, 1)}, actions=())