Skip to content

Conversation

@varruunnn
Copy link
Contributor

This PR adds a comprehensive test suite for js/loader.js to ensure stability of the application entry point. CLOSES #5123
Changes:

Added js/tests/loader.test.js using Jest.

Mocked global requirejs, i18next, and DOM environments to isolate testing.

Verified all logic branches including:

Successful configuration and app loading.

Error handling for i18n initialization and language switching.

Content updates across different document.readyState scenarios.

Result: Achieved 100% coverage (Statements, Branches, Functions, and Lines) for loader.js.

image

@github-actions
Copy link
Contributor

✅ All Jest tests passed! This PR is ready to merge.

@omsuneri omsuneri self-requested a review January 10, 2026 17:50
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.

Add test for loader.js

1 participant