Skip to content

Commit 4eecf1a

Browse files
committed
fix: open on Clean tab (index 0) instead of Find/Replace (index 2)
1 parent 2560da7 commit 4eecf1a

2 files changed

Lines changed: 10 additions & 1 deletion

File tree

src/views/ui/main_window.ui

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@
137137
<enum>QTabWidget::TabShape::Rounded</enum>
138138
</property>
139139
<property name="currentIndex">
140-
<number>2</number>
140+
<number>0</number>
141141
</property>
142142
<property name="documentMode">
143143
<bool>false</bool>

tests/integration/test_main_window.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -335,3 +335,12 @@ def test_error_signal_shows_critical_dialog(self, window, monkeypatch, qtbot):
335335
qtbot.wait(10)
336336
assert len(calls) == 1
337337
assert "something went wrong" in calls[0][2]
338+
339+
340+
class TestDefaultTab:
341+
def test_opens_on_clean_tab(self, window):
342+
"""Tab widget must default to index 0 (Clean tab), not 2 (Find/Replace)."""
343+
from PySide6.QtWidgets import QTabWidget
344+
tab = window.ui.findChild(QTabWidget, "tabWidget")
345+
assert tab is not None
346+
assert tab.currentIndex() == 0

0 commit comments

Comments
 (0)