opensafely-core / opensafely-core/opencodelists
Enforce that screenshots are created with Playwright
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 60
- Forks
- 16
- Avg merge
- 4d 12h
- Merged PRs (30d)
- 17
Description
Why are we doing this?
Once #2574 is complete, we could check that all screenshots linked in the documentation match filenames inside the test that creates the screenshot.
(There is currently test_docs_screenshots_are_used, but that only checks for screenshots linked in the documentation that are missing, and for screenshots that are not used in the documentation.)
Note that this depends on being able to show every feature with every coding system in the tests. So we might want to investigate what the available fixtures allow us to screenshot. Otherwise, we may find that there are required screenshots that we can't yet create, due to a lack of suitable coding system fixtures.
How will we know when it's done?
When there is a test that checks the screenshots filenames against those generated by Playwright.
What are we doing?
- Verifying that we can create screenshots that we might need: can we use fixtures from every coding system in the Playwright tests?
- Adding a test to check that screenshots correspond to filenames created with Playwright.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the dependency on #2574 and the existing test_docs_screenshots_are_used test. Then inspect the Playwright tests and available coding-system fixtures to determine whether the required screenshots can be created. Done means a test compares documentation screenshot filenames with those generated by Playwright.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- playwright, python
- Domain
- documentation, testing-qa
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100