pytest-dev / pytest-dev/pytest-qt

[Feature Request] Should qtbot be able to take+save screenshots?

Open
#264 18 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

question :question:
Dominant language
Python
Stars
455
Forks
72
Avg merge
12h 26m
Merged PRs (30d)
1

Description

Often when dealing with CI systems, I would love to able to view a screenshot of what a QWidget looked like. It got me thinking, how hard is it to take a screenshot of a QWidget, and apparently it's not difficult at all, which got me wondering if this was some functionality pytest-qt should offer.

I would be happy to attempt to integrate this functionality (I've never written anything for a pytest plugin before), but before I did so, I figured I would ask what folks here thought.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the existing qtbot API and how QWidget screenshot capture and saving could fit the pytest-qt plugin. Define the supported capture and save behavior for CI, then add coverage showing that a QWidget screenshot is saved.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
testing
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.