[PR #978] [MERGED] [Test] Fix state leakage between unit tests #1255

Closed
opened 2026-10-31 22:20:52 +00:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Comfy-Org/desktop/pull/978
Author: @webfiltered
Created: 2/22/2025
Status: ✅ Merged
Merged: 2/22/2025
Merged by: @webfiltered

Base: main ← Head: state-leakage


📝 Commits (1)

  • b4d6485 [Test] Fix state leakage between unit tests

📊 Changes

10 files changed (+104 additions, -103 deletions)

View changed files

📝 tests/unit/config/comfyServerConfig.test.ts (+10 -10)
📝 tests/unit/desktopApp.test.ts (+16 -25)
📝 tests/unit/handlers/appinfoHandlers.test.ts (+7 -7)
📝 tests/unit/install/installationManager.test.ts (+36 -31)
📝 tests/unit/main-process/appWindow.test.ts (+5 -5)
📝 tests/unit/main-process/comfyDesktopApp.test.ts (+4 -4)
📝 tests/unit/services/telemetry.test.ts (+12 -10)
📝 tests/unit/setup.ts (+11 -10)
📝 tests/unit/store/desktopConfig.test.ts (+1 -1)
📝 vite.config.ts (+2 -0)

📄 Description

  • Unit tests are now isolated by performing a full reset of all mocks.
  • Default mocks are now added using the proper default mock syntax, rather than adding a resettable mock at the start of a file.

┆Issue is synchronized with this Notion page by Unito


🔄 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/Comfy-Org/desktop/pull/978 **Author:** [@webfiltered](https://github.com/webfiltered) **Created:** 2/22/2025 **Status:** ✅ Merged **Merged:** 2/22/2025 **Merged by:** [@webfiltered](https://github.com/webfiltered) **Base:** `main` ← **Head:** `state-leakage` --- ### 📝 Commits (1) - [`b4d6485`](https://github.com/Comfy-Org/desktop/commit/b4d6485053de6affd84fc1a5420dfcf4654926ad) [Test] Fix state leakage between unit tests ### 📊 Changes **10 files changed** (+104 additions, -103 deletions) <details> <summary>View changed files</summary> 📝 `tests/unit/config/comfyServerConfig.test.ts` (+10 -10) 📝 `tests/unit/desktopApp.test.ts` (+16 -25) 📝 `tests/unit/handlers/appinfoHandlers.test.ts` (+7 -7) 📝 `tests/unit/install/installationManager.test.ts` (+36 -31) 📝 `tests/unit/main-process/appWindow.test.ts` (+5 -5) 📝 `tests/unit/main-process/comfyDesktopApp.test.ts` (+4 -4) 📝 `tests/unit/services/telemetry.test.ts` (+12 -10) 📝 `tests/unit/setup.ts` (+11 -10) 📝 `tests/unit/store/desktopConfig.test.ts` (+1 -1) 📝 `vite.config.ts` (+2 -0) </details> ### 📄 Description - Unit tests are now isolated by performing a full reset of all mocks. - Default mocks are now added using the proper default mock syntax, rather than adding a resettable mock at the start of a file. ┆Issue is synchronized with this [Notion page](https://www.notion.so/PR-978-Test-Fix-state-leakage-between-unit-tests-1a26d73d36508143809dfb07d80bae63) by [Unito](https://www.unito.io) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-31 22:20:52 +00: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
Comfy-Org/desktop#1255
No description provided.