mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-11-05 09:33:25 -08:00
[Tests] Name the menus and dialogs the shell GUI tests drive (#7695)
Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
This commit is contained in:
parent
ee57d740c2
commit
d2abd645e8
14 changed files with 81 additions and 0 deletions
11
Testing/dialog_lifecycle_test.xml
Normal file
11
Testing/dialog_lifecycle_test.xml
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
<events>
|
||||
<!-- Open and close Settings dialog (modal exec) -->
|
||||
<event widget="MainWindow/menubar" command="activate" arguments="cockatriceMenu" />
|
||||
<event widget="MainWindow/menubar/cockatriceMenu" command="activate" arguments="actionSettings" />
|
||||
<event widget="MainWindow/settingsDialog" command="key" arguments="16777216" />
|
||||
|
||||
<!-- Open and close About dialog (modal exec) -->
|
||||
<event widget="MainWindow/menubar" command="activate" arguments="helpMenu" />
|
||||
<event widget="MainWindow/menubar/helpMenu" command="activate" arguments="&About Cockatrice" />
|
||||
<event widget="MainWindow/aboutDialog" command="key" arguments="16777216" />
|
||||
</events>
|
||||
19
Testing/menu_open_close_test.xml
Normal file
19
Testing/menu_open_close_test.xml
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
<events>
|
||||
<!-- Test 1: Open and close each top-level menu -->
|
||||
|
||||
<!-- Cockatrice menu -->
|
||||
<event widget="MainWindow/menubar" command="activate" arguments="cockatriceMenu" />
|
||||
<event widget="MainWindow" command="key" arguments="16777216" />
|
||||
|
||||
<!-- Database menu -->
|
||||
<event widget="MainWindow/menubar" command="activate" arguments="dbMenu" />
|
||||
<event widget="MainWindow" command="key" arguments="16777216" />
|
||||
|
||||
<!-- Tabs menu -->
|
||||
<event widget="MainWindow/menubar" command="activate" arguments="tabsMenu" />
|
||||
<event widget="MainWindow" command="key" arguments="16777216" />
|
||||
|
||||
<!-- Help menu -->
|
||||
<event widget="MainWindow/menubar" command="activate" arguments="helpMenu" />
|
||||
<event widget="MainWindow" command="key" arguments="16777216" />
|
||||
</events>
|
||||
6
Testing/nonmodal_manage_sets_test.xml
Normal file
6
Testing/nonmodal_manage_sets_test.xml
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
<events>
|
||||
<!-- Test non-modal dialog lifecycle: open and close Manage Sets (QMainWindow) -->
|
||||
<event widget="MainWindow/menubar" command="activate" arguments="dbMenu" />
|
||||
<event widget="MainWindow/menubar/dbMenu" command="activate" arguments="&Manage sets..." />
|
||||
<event widget="MainWindow/manageSetsWindow" command="key" arguments="16777216" />
|
||||
</events>
|
||||
6
Testing/nonmodal_tip_test.xml
Normal file
6
Testing/nonmodal_tip_test.xml
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
<events>
|
||||
<!-- Test non-modal dialog lifecycle: open and close Tip of the Day -->
|
||||
<event widget="MainWindow/menubar" command="activate" arguments="helpMenu" />
|
||||
<event widget="MainWindow/menubar/helpMenu" command="activate" arguments="&Tip of the Day" />
|
||||
<event widget="MainWindow/tipOfTheDayDialog" command="key" arguments="16777216" />
|
||||
</events>
|
||||
6
Testing/nonmodal_view_log_test.xml
Normal file
6
Testing/nonmodal_view_log_test.xml
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
<events>
|
||||
<!-- Test non-modal dialog lifecycle: open and close ViewLog -->
|
||||
<event widget="MainWindow/menubar" command="activate" arguments="helpMenu" />
|
||||
<event widget="MainWindow/menubar/helpMenu" command="activate" arguments="View &Debug Log" />
|
||||
<event widget="MainWindow/viewLogDialog" command="key" arguments="16777216" />
|
||||
</events>
|
||||
6
Testing/settings_dialog_test.xml
Normal file
6
Testing/settings_dialog_test.xml
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
<events>
|
||||
<!-- Open Settings dialog via Cockatrice menu, then close with Escape -->
|
||||
<event widget="MainWindow/menubar" command="activate" arguments="cockatriceMenu" />
|
||||
<event widget="MainWindow/menubar/cockatriceMenu" command="activate" arguments="actionSettings" />
|
||||
<event widget="MainWindow/settingsDialog" command="key" arguments="16777216" />
|
||||
</events>
|
||||
Loading…
Add table
Add a link
Reference in a new issue