Removed not needed workaround for check-updates on dom0
And fixed test referring to it.
This commit is contained in:
parent
3d7d99081c
commit
74eba3bb7f
@ -20,8 +20,6 @@
|
||||
#
|
||||
#
|
||||
|
||||
import os
|
||||
import os.path
|
||||
import subprocess
|
||||
from PyQt5 import QtWidgets # pylint: disable=import-error
|
||||
|
||||
@ -245,15 +243,11 @@ class GlobalSettingsWindow(ui_globalsettingsdlg.Ui_GlobalSettings,
|
||||
qmemman_config_file.close()
|
||||
|
||||
def __init_updates__(self):
|
||||
# TODO: remove workaround when it is no longer needed
|
||||
self.dom0_updates_file_path = '/var/lib/qubes/updates/disable-updates'
|
||||
|
||||
try:
|
||||
self.updates_dom0_val = bool(self.qvm_collection.domains[
|
||||
'dom0'].features['service.qubes-update-check'])
|
||||
except KeyError:
|
||||
self.updates_dom0_val =\
|
||||
not os.path.isfile(self.dom0_updates_file_path)
|
||||
self.updates_dom0_val = True
|
||||
|
||||
self.updates_dom0.setChecked(self.updates_dom0_val)
|
||||
|
||||
|
@ -128,8 +128,7 @@ class GlobalSettingsTest(unittest.TestCase):
|
||||
dom0_updates = self.qapp.domains[
|
||||
'dom0'].features['service.qubes-update-check']
|
||||
except KeyError:
|
||||
self.skipTest("check_updates_dom0 property not implemented")
|
||||
return
|
||||
dom0_updates = True
|
||||
|
||||
self.assertEqual(bool(dom0_updates),
|
||||
self.dialog.updates_dom0.isChecked(),
|
||||
|
Loading…
Reference in New Issue
Block a user