Hopefully fix some wayland keyboard stuff.
This commit is contained in:
1 parent
2d9790de88
commit
eeb7bd046f
6 files changed
+124
-12
No files matched your search
@@ -0,0 +1,30 @@
|
||||
import sys
|
||||
import unittest
|
||||
from pathlib import Path
|
||||
from unittest import mock
|
||||
|
||||
sys.path.insert(0, str(Path(__file__).resolve().parents[1] / "src"))
|
||||
|
||||
from cthulhu.plugins.ByeCthulhu.plugin import ByeCthulhu
|
||||
|
||||
|
||||
class ByeCthulhuRegressionTests(unittest.TestCase):
|
||||
def test_activate_only_connects_stop_signal_once(self):
|
||||
plugin = ByeCthulhu()
|
||||
signalManager = mock.Mock()
|
||||
signalManager.connectSignal.return_value = 42
|
||||
plugin.app = mock.Mock()
|
||||
plugin.app.getSignalManager.return_value = signalManager
|
||||
|
||||
plugin.activate(plugin)
|
||||
plugin.activate(plugin)
|
||||
|
||||
signalManager.connectSignal.assert_called_once_with(
|
||||
"stop-application-completed",
|
||||
plugin.process,
|
||||
"default",
|
||||
)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
unittest.main()
|
||||
Reference in new issue
Block a user