From 11fd2cf1150a1565657b92ffe681abc2773881a2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marek=20Marczykowski-G=C3=B3recki?= Date: Mon, 6 Nov 2017 16:03:04 +0100 Subject: [PATCH] tests/backupcompatibility: drop R1 format tests It is no longer supported. --- qubes/tests/integ/backupcompatibility.py | 137 ----------------------- 1 file changed, 137 deletions(-) diff --git a/qubes/tests/integ/backupcompatibility.py b/qubes/tests/integ/backupcompatibility.py index d53029f8..fba058c0 100644 --- a/qubes/tests/integ/backupcompatibility.py +++ b/qubes/tests/integ/backupcompatibility.py @@ -30,25 +30,6 @@ import re import qubes.tests import qubes.tests.integ.backup -QUBESXML_R2B2 = ''' - - - - - - - - - - - - - - - - - -''' QUBESXML_R2 = ''' @@ -129,10 +110,6 @@ X-Qubes-VmName=%VMNAME% Icon=%VMDIR%/icon.png ''' -QUBESXML_R1 = ''' - -''' - BACKUP_HEADER_R2 = '''version=3 hmac-algorithm=SHA512 crypto-algorithm=aes-256-cbc @@ -424,120 +401,6 @@ class TC_00_BackupCompatibility( self.assertEqual(value, actual_value, 'VM {} - property {}'.format(vm.name, prop)) - def test_100_r1(self): - self.create_v1_files(r2b2=False) - - f = open(self.fullpath("qubes.xml"), "w") - f.write(QUBESXML_R1) - f.close() - - self.restore_backup(self.backupdir, - options={ - 'use-default-template': True, - 'use-default-netvm': True, - }, - ) - common_props = { - 'installed_by_rpm': False, - 'kernel': qubes.property.DEFAULT, - 'kernelopts': qubes.property.DEFAULT, - 'qrexec_timeout': qubes.property.DEFAULT, - 'netvm': qubes.property.DEFAULT, - 'default_user': qubes.property.DEFAULT, - 'internal': qubes.property.DEFAULT, - 'include_in_backups': True, - 'debug': False, - 'maxmem': 4000, # 4063 caped by 10*400 - 'memory': 400, - } - self.assertRestored("test-template-clone", - klass=qubes.vm.templatevm.TemplateVM, - label='gray', - provides_network=False, - **common_props) - testproxy_props = common_props.copy() - testproxy_props.update( - label='yellow', - provides_network=True, - memory=200, - maxmem=2000, - template=self.app.default_template.name, - ) - self.assertRestored("test-testproxy", - klass=qubes.vm.appvm.AppVM, - **testproxy_props) - self.assertRestored("test-work", - klass=qubes.vm.appvm.AppVM, - template=self.app.default_template.name, - label='green', - **common_props) - self.assertRestored("test-standalonevm", - klass=qubes.vm.standalonevm.StandaloneVM, - label='red', - **common_props) - self.assertRestored("test-custom-template-appvm", - klass=qubes.vm.appvm.AppVM, - template='test-template-clone', - label='yellow', - **common_props) - - def test_200_r2b2(self): - self.create_v1_files(r2b2=True) - - f = open(self.fullpath("qubes.xml"), "w") - f.write(QUBESXML_R2B2) - f.close() - - self.restore_backup(self.backupdir, options={ - 'use-default-template': True, - 'use-default-netvm': True, - }) - common_props = { - 'installed_by_rpm': False, - 'kernel': qubes.property.DEFAULT, - 'kernelopts': qubes.property.DEFAULT, - 'qrexec_timeout': qubes.property.DEFAULT, - 'netvm': qubes.property.DEFAULT, - 'default_user': qubes.property.DEFAULT, - 'internal': qubes.property.DEFAULT, - 'include_in_backups': True, - 'debug': False, - 'maxmem': 1535, - 'memory': 400, - } - template_clone_props = common_props.copy() - template_clone_props.update( - label='green', - provides_network=False, - ) - self.assertRestored("test-template-clone", - klass=qubes.vm.templatevm.TemplateVM, - **template_clone_props) - testproxy_props = common_props.copy() - testproxy_props.update( - label='red', - provides_network=True, - memory=200, - template=self.app.default_template.name, - ) - self.assertRestored("test-testproxy", - klass=qubes.vm.appvm.AppVM, - **testproxy_props) - self.assertRestored("test-work", - klass=qubes.vm.appvm.AppVM, - template=self.app.default_template.name, - label='green', - **common_props) - self.assertRestored("test-standalonevm", - klass=qubes.vm.standalonevm.StandaloneVM, - label='blue', - **common_props) - self.assertRestored("test-custom-template-appvm", - klass=qubes.vm.appvm.AppVM, - template='test-template-clone', - label='yellow', - **common_props) - def test_210_r2(self): self.create_v3_backup(False)