SSWConsulting / SSWConsulting/SSW.Website

✨ Add a playwright test for image urls with incorrect spacing

Open
#2,740 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
HTML
Stars
14
Forks
10
Avg merge
13h 51m
Merged PRs (30d)
38

Description

@wicksipedia

The Pain ❌

Newsletters are frequently being uploaded with image urls that break when pushed to production. This issue occurs because the files systems in Windows (i.e. FAT or NTFS) are case-insensitive but the urls are case-sensitive, so when the images get pushed to production they 404.

example:

C:/SSW.Website/public/android-chrome-192x192.png is the same as C:/SSW.Website/public/android-Chrome-192x192.png in NTFS

However

https://www.ssw.com.au/android-chrome-192x192.png is not the same as https://www.ssw.com.au/android-Chrome-192x192.png

🤔 The solution

I'd recommend writing a playwright test to fix the casing of the image URLs if they match a file in the GitHub repo with incorrect casing.

Alternative solutions 🛣️

A playwright test that fails if someone links to an image URL in the GitHub repo with incorrect spacing would also solve this issue. However this is also likely to lead to confusion and frustration for marketing team members.

In general we want newsletters to be published as quickly as possible with little time spent fixing build errors.

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 locating the repository's existing Playwright tests and the newsletter image URL handling. Reproduce the case-mismatch example against a repository image, then confirm whether the intended behavior is to correct the URL or fail the test for the production 404 scenario.

Written by the indexing model from the issue text.

Assessment

Tech stack
playwright
Domain
testing
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 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.