[PR #71] [MERGED] Fix tests compiling without .babelrc #265

Closed
opened 2026-02-27 19:17:30 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/EddieTheCubeHead/Stagnum/pull/71
Author: @tuomasmustakallio
Created: 2/12/2024
Status: Merged
Merged: 2/13/2024
Merged by: @tuomasmustakallio

Base: masterHead: fix-testing-without-babelrc


📝 Commits (1)

  • a861bb6 Fix tests compiling without .babelrc

📊 Changes

3 files changed (+51 additions, -4 deletions)

View changed files

client/.babelrc (+0 -3)
📝 client/jest.config.ts (+50 -0)
📝 client/next.config.mjs (+1 -1)

📄 Description

Tests compile with babel instead of next.js compiler. Babel is used for testing because it seems to be a bit more accurate than v8. This can be changed if it affects performance too much by compiling with babel.
Setting up Jest with Babel:
https://nextjs.org/docs/pages/building-your-application/testing/jest

Tradeoffs of v8 vs Babel
https://github.com/jestjs/jest/issues/11188


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/EddieTheCubeHead/Stagnum/pull/71 **Author:** [@tuomasmustakallio](https://github.com/tuomasmustakallio) **Created:** 2/12/2024 **Status:** ✅ Merged **Merged:** 2/13/2024 **Merged by:** [@tuomasmustakallio](https://github.com/tuomasmustakallio) **Base:** `master` ← **Head:** `fix-testing-without-babelrc` --- ### 📝 Commits (1) - [`a861bb6`](https://github.com/EddieTheCubeHead/Stagnum/commit/a861bb6bbc8ebab7a38e8b14e5a88217a986fd9e) Fix tests compiling without .babelrc ### 📊 Changes **3 files changed** (+51 additions, -4 deletions) <details> <summary>View changed files</summary> ➖ `client/.babelrc` (+0 -3) 📝 `client/jest.config.ts` (+50 -0) 📝 `client/next.config.mjs` (+1 -1) </details> ### 📄 Description Tests compile with babel instead of next.js compiler. Babel is used for testing because it seems to be a bit more accurate than v8. This can be changed if it affects performance too much by compiling with babel. Setting up Jest with Babel: https://nextjs.org/docs/pages/building-your-application/testing/jest Tradeoffs of v8 vs Babel https://github.com/jestjs/jest/issues/11188 --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-02-27 19:17:30 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/Stagnum#265
No description provided.