Acceptance run with screenshots and the MVP table; window teardown no longer reaches destroyed menus or toolbar (11.5)

This commit is contained in:
雷电芽衣 committed 2026-09-30 14:39:11 -04:00
1 parent 51bec23cc5
commit e94fd73573
30 files changed
+791 -3

No files matched your search

+12
View File
@@ -42,6 +42,7 @@ class KeyboardShortcutsSheetTests : public QObject {
Q_OBJECT
private slots:
void initTestCase();
void theWindowGoesWhileThePanelHoldsTheKeys();
void cleanup();
void aRecordedKeyRemapsItsMenuEntryOnSave();
void recordingWaitsForARealKey();
@@ -182,5 +183,16 @@ void KeyboardShortcutsSheetTests::cancelKeepsWhatWasSaved()
QCOMPARE(ShortcutSettings::shared().overrides().size(), 1);
}
// Hiding the panel moves the focus while the menus go.
void KeyboardShortcutsSheetTests::theWindowGoesWhileThePanelHoldsTheKeys()
{
auto bar = std::make_unique<Bar>();
QWidget &panel = opened(*bar);
QVERIFY(QTest::qWaitForWindowActive(&panel));
QTRY_COMPARE(QApplication::activeWindow(), &panel);
bar.reset();
QVERIFY(!shownPanel());
}
QTEST_MAIN(KeyboardShortcutsSheetTests)
#include "KeyboardShortcutsSheetTests.moc"