Skip to content

test: add pytest-qt GUI tests #1132

Draft
andychoquette wants to merge 1 commit intoaws-deadline:mainlinefrom
andychoquette:chore/add-automated-ui-tests
Draft

test: add pytest-qt GUI tests #1132
andychoquette wants to merge 1 commit intoaws-deadline:mainlinefrom
andychoquette:chore/add-automated-ui-tests

Conversation

@andychoquette
Copy link
Copy Markdown
Contributor

DRAFT - WIP

Add pytest-qt tests that replace the Squish tst_verify_settings_dialogue and tst_verify_gui_submitter_bundles test suites. These tests use MockDeadlineBackend to provide fake API responses in-process, requiring no AWS credentials, no Squish license, and no external infrastructure.

New files:

  • test/gui/conftest.py: shared fixture for MockDeadlineBackend
  • test/gui/test_settings_dialogue.py: 14 tests for the config dialog
  • test/gui/test_gui_submitter_bundles.py: 6 tests for the GUI submitter

Changes:

  • mock_deadline_backend.py: add ListFarms, ListQueues, ListStorageProfilesForQueue APIs and storage_profiles storage
  • hatch.toml: add [envs.gui] with pytest-qt and PySide6 deps
  • code_quality.yml: add GUITests job (Linux/macOS/Windows matrix)

Run locally with: hatch run gui:test

Fixes:

What was the problem/requirement? (What/Why)

What was the solution? (How)

What is the impact of this change?

How was this change tested?

See DEVELOPMENT.md for information on running tests.

  • Have you run the unit tests?
  • Have you run the integration tests?
  • Have you made changes to the download or asset_sync modules? If so, then it is highly recommended
    that you ensure that the docker-based unit tests pass.

Was this change documented?

  • Are relevant docstrings in the code base updated?
  • Has the README.md been updated? If you modified CLI arguments, for instance.

Does this PR introduce new dependencies?

This library is designed to be integrated into third-party applications that have bespoke and customized deployment environments. Adding dependencies will increase the chance of library version conflicts and incompatabilities. Please evaluate the addition of new dependencies. See the Dependencies section of DEVELOPMENT.md for more details.

  • This PR adds one or more new dependency Python packages. I acknowledge I have reviewed the considerations for adding dependencies in DEVELOPMENT.md.
  • This PR does not add any new dependencies.

Is this a breaking change?

A breaking change is one that modifies a public contract in a way that is not backwards compatible. See the
Public Contracts section
of the DEVELOPMENT.md for more information on the public contracts.

If so, then please describe the changes that users of this package must make to update their scripts, or Python applications.

Does this change impact security?

  • Does the change need to be threat modeled? For example, does it create or modify files/directories that must only be readable by the process owner?
    • If so, then please label this pull request with the "security" label. We'll work with you to analyze the threats.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@andychoquette andychoquette changed the title test: add pytest-qt GUI tests as open-source alternative to Squish test: add pytest-qt GUI tests Apr 23, 2026
@github-actions github-actions Bot added the waiting-on-maintainers Waiting on the maintainers to review. label Apr 23, 2026
@andychoquette andychoquette force-pushed the chore/add-automated-ui-tests branch 4 times, most recently from d4a820e to 9059b82 Compare April 23, 2026 21:41
Add pytest-qt tests that replace the Squish tst_verify_settings_dialogue
and tst_verify_gui_submitter_bundles test suites. These tests use
MockDeadlineBackend to provide fake API responses in-process, requiring
no AWS credentials, no Squish license, and no external infrastructure.

New files:
- test/gui/conftest.py: shared fixture for MockDeadlineBackend
- test/gui/test_settings_dialogue.py: 14 tests for the config dialog
- test/gui/test_gui_submitter_bundles.py: 6 tests for the GUI submitter

Changes:
- mock_deadline_backend.py: add ListFarms, ListQueues,
  ListStorageProfilesForQueue APIs and storage_profiles storage
- hatch.toml: add [envs.gui] with pytest-qt and PySide6 deps
- code_quality.yml: add GUITests job (Linux/macOS/Windows matrix)

Run locally with: hatch run gui:test

Signed-off-by: Andy Choquette <apcho@amazon.com>
Signed-off-by: Andy Choquette <78888816+andychoquette@users.noreply.github.com>
@andychoquette andychoquette force-pushed the chore/add-automated-ui-tests branch from 9059b82 to 33f77a6 Compare April 23, 2026 21:43
@andychoquette andychoquette self-assigned this Apr 23, 2026
Comment thread DEVELOPMENT.md
Comment on lines +213 to +223
### GUI Tests (pytest-qt)

GUI tests are located under the `test/gui` directory. They use [pytest-qt](https://pytest-qt.readthedocs.io/) to test Qt widgets and dialogs in-process, with `MockDeadlineBackend` providing fake API responses. No AWS credentials or Squish license required.

#### Running GUI Tests

```sh
hatch run gui:test
```

These tests run automatically in CI on Linux, macOS, and Windows as part of the Code Quality workflow.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since these don't actually need a screen or start up a GUI, could we run them with the rest of the unit tests?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

waiting-on-maintainers Waiting on the maintainers to review.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants