Problem
UIVerification.Verify() opens the real MCPTestWindow and never closes it after the diagnostic completes.
Evidence
Editor/UIVerification.cs:21-30 calls MCPTestWindow.ShowWindow(), resets state, runs checks, and returns.
Editor/MCPTestWindow.cs:44-48 uses GetWindow<MCPTestWindow>(), creating/focusing a visible editor window.
- There is no
Close() or cleanup after verification.
Impact
Running UI verification leaves a visible Nexus Unity Test window/tab in the user layout. Repeated runs refocus it rather than cleaning it up.
Suggested fix
Close the test window after verification, or create a hidden temporary instance if visibility is not required.
Source report
Imported from audit report item: unity-antipattern (6) / Editor/UIVerification.cs:25.
Problem
UIVerification.Verify()opens the realMCPTestWindowand never closes it after the diagnostic completes.Evidence
Editor/UIVerification.cs:21-30callsMCPTestWindow.ShowWindow(), resets state, runs checks, and returns.Editor/MCPTestWindow.cs:44-48usesGetWindow<MCPTestWindow>(), creating/focusing a visible editor window.Close()or cleanup after verification.Impact
Running UI verification leaves a visible
Nexus Unity Testwindow/tab in the user layout. Repeated runs refocus it rather than cleaning it up.Suggested fix
Close the test window after verification, or create a hidden temporary instance if visibility is not required.
Source report
Imported from audit report item:
unity-antipattern (6)/Editor/UIVerification.cs:25.