Add unit tests for config and i18n
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 70/100
- Issue type
- Feature
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- electron, github-actions, javascript, node.js
- Domain
- ci-cd, internationalization, testing
Research direction
Start with src/renderer/shared/i18n.js and src/main/config.js, then read .github/workflows/build.yml to see how the project runs its build. Add node:test coverage for the listed locale, translation, validation, migration, and merge cases; decide whether config.js needs an Electron mock or a small refactor. Done when npm test passes and runs in the build workflow.
Written by the indexing model from the issue text.
Description
The project has no tests yet. Two modules are pure enough to start with:
src/renderer/shared/i18n.js:resolve()(explicit setting, "auto" with various locales likede-DE,de_AT,TR, empty),translate()(placeholders, fallback to Turkish/key), and a check that every language has the same keys and placeholders asen. That last one would have caught missing strings in translation PRs automatically.src/main/config.js:validate,migrateandmergeInto(invalid enum values fall back to defaults, unknown keys are dropped, old settings files migrate). It requireselectronat the top, so it may need a small refactor or a mock.
Suggestions:
- Use the built-in
node:testrunner to avoid new dependencies, with annpm testscript. - Run
npm testin.github/workflows/build.yml.
Happy to discuss the approach in this issue first.
- Dominant language
- JavaScript
- Stars
- 1
- Forks
- 2
- Avg merge
- 1d 10h
- Merged PRs (30d)
- 2
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
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.
More from Primeteumm/Screenshot-Enhancer
-
documentation good first issue
Difficulty 1/5 Under an hour Newbie friendliness 94/100
-
documentation good first issue
Difficulty 1/5 Under an hour Newbie friendliness 89/100
-
enhancement good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
-
enhancement good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
enhancement good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
All issues in Primeteumm/Screenshot-Enhancer
Similar issues
-
FEATURE REQUEST
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
linuxmint/cinnamon-spices-extensions#1193 ·
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
Fei2411/DeepSeek-Bot#703 ·
-
area:web first-timers-only good first issue
Difficulty 1/5 Under an hour Newbie friendliness 95/100
career-ops-hq/career-ops#6264 ·
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 74/100
catppuccin/firefox#21 ·
-
Difficulty 1/5 Under an hour Newbie friendliness 83/100
cline/mcp-marketplace#3394 ·