Skip to content

[tests] Review and refactor translation tests #3792

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

KristjanESPERANTO
Copy link
Collaborator

@KristjanESPERANTO KristjanESPERANTO commented May 26, 2025

I have refactored the translations tests, they should now be clearer and easier to understand. There should be no functional impact.

I have discarded the original approach of also replacing XMLHttpRequest with fetch in the file js/translator.js. I had managed to get it to work functionally, but I couldn't get the tests to work.

@KristjanESPERANTO KristjanESPERANTO changed the title refactor: simplify loadJSON function in translator.js [refactor] Simplify loadJSON function in translator.js May 26, 2025
@KristjanESPERANTO KristjanESPERANTO marked this pull request as draft May 26, 2025 20:14
rejas pushed a commit that referenced this pull request Jun 9, 2025
…s" (#3809)

While working on the translations (in #3792 and #3794) I realised that
the e2e "Same keys" tests were not working entirely. There was also a
TODO entry for this in the test, as well as a try-catch-block
workaround. I therefore fixed and refactored it.

I also sorted the translations in `translations/translations.js`, so
that the test outputs are alphabetically.
@KristjanESPERANTO KristjanESPERANTO changed the title [refactor] Simplify loadJSON function in translator.js [tests] Review and refactor translation tests Jun 9, 2025
@KristjanESPERANTO KristjanESPERANTO marked this pull request as ready for review June 9, 2025 15:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant