[gnome-builder/wip/gtk4-port: 1773/1774] plugins/testui: add menu for run all tests




commit c651b78bd7884ae63867c629e88d6e12b31b4f44
Author: Christian Hergert <chergert redhat com>
Date:   Sat Jul 9 16:57:13 2022 -0700

    plugins/testui: add menu for run all tests

 src/plugins/buildui/gtk/menus.ui        |  1 +
 src/plugins/testui/gtk/menus.ui         | 14 ++++++++++++++
 src/plugins/testui/testui.gresource.xml |  1 +
 src/plugins/testui/testui.plugin        |  1 +
 4 files changed, 17 insertions(+)
---
diff --git a/src/plugins/buildui/gtk/menus.ui b/src/plugins/buildui/gtk/menus.ui
index c314df113..df725cf7b 100644
--- a/src/plugins/buildui/gtk/menus.ui
+++ b/src/plugins/buildui/gtk/menus.ui
@@ -116,6 +116,7 @@
         <attribute name="verb-icon">builder-run-start-symbolic</attribute>
       </item>
     </section>
+    <section id="run-menu-tests-section"/>
     <section id="run-menu-settings-section">
       <attribute name="label" translatable="yes">Settings</attribute>
       <submenu id="run-menu-appearance">
diff --git a/src/plugins/testui/gtk/menus.ui b/src/plugins/testui/gtk/menus.ui
new file mode 100644
index 000000000..7bb90d9e6
--- /dev/null
+++ b/src/plugins/testui/gtk/menus.ui
@@ -0,0 +1,14 @@
+<?xml version="1.0"?>
+<interface>
+  <menu id="run-menu">
+    <section id="run-menu-tests-section">
+      <item>
+        <attribute name="id">run-unit-tests</attribute>
+        <attribute name="action">test-manager.test-all</attribute>
+        <attribute name="label" translatable="yes">Run all Unit Tests</attribute>
+        <attribute name="verb-icon-name">builder-unit-tests-symbolic</attribute>
+        <attribute name="accel">&lt;control&gt;&lt;shift&gt;&lt;alt&gt;u</attribute>
+      </item>
+    </section>
+  </menu>
+</interface>
diff --git a/src/plugins/testui/testui.gresource.xml b/src/plugins/testui/testui.gresource.xml
index 7b793ce55..0e756bdea 100644
--- a/src/plugins/testui/testui.gresource.xml
+++ b/src/plugins/testui/testui.gresource.xml
@@ -2,6 +2,7 @@
 <gresources>
   <gresource prefix="/plugins/testui">
     <file>testui.plugin</file>
+    <file preprocess="xml-stripblanks">gtk/menus.ui</file>
     <file preprocess="xml-stripblanks">gbp-testui-output-panel.ui</file>
     <file preprocess="xml-stripblanks">gbp-testui-panel.ui</file>
   </gresource>
diff --git a/src/plugins/testui/testui.plugin b/src/plugins/testui/testui.plugin
index a0ae7f392..5c0309b7e 100644
--- a/src/plugins/testui/testui.plugin
+++ b/src/plugins/testui/testui.plugin
@@ -2,6 +2,7 @@
 Authors=Christian Hergert <christian hergert me>
 Builtin=true
 Copyright=Copyright © 2017-2022 Christian Hergert
+Depends=buildui;
 Description=Unit Testing
 Embedded=_gbp_testui_register_types
 Hidden=true


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]