Open
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #324 +/- ##
==========================================
- Coverage 75.26% 75.24% -0.03%
==========================================
Files 52 52
Lines 8950 8950
==========================================
- Hits 6736 6734 -2
- Misses 2214 2216 +2 ☔ View full report in Codecov by Sentry. |
marmarek
requested changes
Dec 12, 2024
Menu needs this.
d5644e8 to
5f8a5c6
Compare
marmarek
reviewed
Dec 14, 2024
Comment on lines
+651
to
+656
| self._qubes['test-vm2'] = MockQube(name="test-vm2", qapp=self, | ||
| features={'menu-favorites': ''}) | ||
| self._qubes['dom0'].features['menu-initial-page'] = 'favorites_page' | ||
| self._qubes['dom0'].features['menu-sort-running'] = '1' | ||
| self._qubes['dom0'].features['menu-position'] = 'mouse' | ||
|
|
Member
There was a problem hiding this comment.
I'm not against it here, but wouldn't it be more convenient to have it in desktop-linux-menu, in a wrapper?
Simply add a file somewhere in tests/ directory that does:
def main():
"""
Start the menu app
"""
# if X is not running or other weird stuff is happening, exit with exit code
# 6 to signal to the service that this should not be restarted
if not Gtk.init_check()[0]:
sys.exit(6)
qapp = qubesadmin.tests.mock_app.MockQubesComplete()
qapp._qubes['test-vm2'] = MockQube(name="test-vm2", qapp=qapp,
features={'menu-favorites': ''})
qapp._qubes['dom0'].features['menu-initial-page'] = 'favorites_page'
qapp._qubes['dom0'].features['menu-sort-running'] = '1'
qapp._qubes['dom0'].features['menu-position'] = 'mouse'
qapp.update_vm_calls()
dispatcher = qubesadmin.tests.mock_app.MockDispatcher(qapp)
app = AppMenu(qapp, dispatcher)
app.run(sys.argv)
if __name__ == '__main__':
sys.exit(main())
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Menu needs this.