Improve and fix testing for commands.

Review Request #13071 — Created May 25, 2023 and submitted — Latest diff uploaded

Information

RBTools
release-5.x

Reviewers

Our command testing support has been pretty under-utilized so far. While
working on some new tests, I encountered some crashes that could occur
if setting up two command runs in one test.

This change fixes that, along with some unbound variables. It also adds:

  • Full typing throughout the command test helpers
  • JSON output in the command results
  • Generics for the test helper class, to help type instances of the
    command classes

Upcoming tests will use this support.

Unit tests pass.

Tested with in-progress changes.

Diff Revision 1 (Latest)

Commits

First Last Summary ID Author
Improve and fix testing for commands.
Our command testing support has been pretty under-utilized so far. While working on some new tests, I encountered some crashes that could occur if setting up two command runs in one test. This change fixes that, along with some unbound variables. It also adds: * Full typing throughout the command test helpers * JSON output in the command results * Generics for the test helper class, to help type instances of the command classes Upcoming tests will use this support.
5fba106035ff30391773c7d2909bcf96dff0ef54 Christian Hammond
rbtools/testing/commands.py
Loading...