From 3abf2b24b4fbc8c8b8977fb464219c51063a9555 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marek=20Marczykowski-G=C3=B3recki?= Date: Tue, 17 May 2016 22:56:18 +0200 Subject: [PATCH] tests: check opening URL While at it, fix policy preparation for qvm-open-in-vm tests. QubesOS/qubes-issues#1487 --- tests/vm_qrexec_gui.py | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/tests/vm_qrexec_gui.py b/tests/vm_qrexec_gui.py index db514249..5994acbb 100644 --- a/tests/vm_qrexec_gui.py +++ b/tests/vm_qrexec_gui.py @@ -1441,7 +1441,9 @@ class TC_50_MimeHandlers(qubes.tests.SystemTestsMixin): passio_popen=True) vmpattern = "disp*" else: - self.qrexec_policy('qubes.Filecopy', self.source_vm.name, + self.qrexec_policy('qubes.OpenInVM', self.source_vm.name, + self.target_vmname) + self.qrexec_policy('qubes.OpenURL', self.source_vm.name, self.target_vmname) p = self.source_vm.run("qvm-open-in-vm {} {}".format( self.target_vmname, filename), passio_popen=True) @@ -1573,6 +1575,10 @@ class TC_50_MimeHandlers(qubes.tests.SystemTestsMixin): self.open_file_and_check_viewer(filename, [], ["shotwell", "eog", "display"]) + def test_010_url(self): + self.open_file_and_check_viewer("https://www.qubes-os.org/", [], + ["Firefox", "Iceweasel"]) + def test_100_txt_dispvm(self): filename = "/home/user/test_file.txt" self.prepare_txt(filename) @@ -1622,6 +1628,11 @@ class TC_50_MimeHandlers(qubes.tests.SystemTestsMixin): ["shotwell", "eog", "display"], dispvm=True) + def test_110_url_dispvm(self): + self.open_file_and_check_viewer("https://www.qubes-os.org/", [], + ["Firefox", "Iceweasel"], + dispvm=True) + def load_tests(loader, tests, pattern): try: