Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tests: assertEquals -> assertEqual #615

Merged
merged 9 commits into from
Aug 24, 2024
4 changes: 2 additions & 2 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ checks:tests:
tags:
- vm-kvm
include:
- file: /r4.2/gitlab-base.yml
- file: /r4.3/gitlab-base.yml
project: QubesOS/qubes-continuous-integration
- file: /r4.2/gitlab-host.yml
- file: /r4.3/gitlab-host.yml
project: QubesOS/qubes-continuous-integration
8 changes: 4 additions & 4 deletions qubes/tests/integ/devices_block.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ def test_010_list_dm(self):
found = False
for dev in dev_list:
if dev.ident.startswith('loop'):
self.assertNotEquals(dev.serial, self.img_path,
self.assertNotEqual(dev.serial, self.img_path,
"Device {} ({}) should not be listed as it is used in "
"device-mapper".format(dev, self.img_path)
)
Expand Down Expand Up @@ -163,12 +163,12 @@ def test_011_list_dm_mounted(self):
dev_list = list(self.vm.devices['block'])
for dev in dev_list:
if dev.ident.startswith('loop'):
self.assertNotEquals(dev.serial, self.img_path,
self.assertNotEqual(dev.serial, self.img_path,
"Device {} ({}) should not be listed as it is used in "
"device-mapper".format(dev, self.img_path)
)
else:
self.assertNotEquals(dev.serial, 'test-dm',
self.assertNotEqual(dev.serial, 'test-dm',
"Device {} ({}) should not be listed as it is "
"mounted".format(dev, 'test-dm')
)
Expand All @@ -188,7 +188,7 @@ def test_012_list_dm_delayed(self):
found = False
for dev in dev_list:
if dev.ident.startswith('loop'):
self.assertNotEquals(dev.serial, self.img_path,
self.assertNotEqual(dev.serial, self.img_path,
"Device {} ({}) should not be listed as it is used in "
"device-mapper".format(dev, self.img_path)
)
Expand Down
2 changes: 1 addition & 1 deletion qubes/tests/integ/dispvm.py
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ def test_003_cleanup_destroyed(self):
lines = lines_task.result().splitlines()
self.assertTrue(lines, 'No output received from DispVM')
dispvm_name = lines[0]
self.assertNotEquals(dispvm_name, b"ERROR")
self.assertNotEqual(dispvm_name, b"ERROR")

self.assertNotIn(dispvm_name, self.app.domains)

Expand Down
4 changes: 2 additions & 2 deletions qubes/tests/integ/vm_qrexec_gui.py
Original file line number Diff line number Diff line change
Expand Up @@ -473,10 +473,10 @@ def test_210_time_sync(self):
# get current time
current_time, _ = self.loop.run_until_complete(
self.testvm1.run_for_stdio('date -u +%s'))
self.assertAlmostEquals(int(vm_time), int(current_time), delta=30)
self.assertAlmostEqual(int(vm_time), int(current_time), delta=30)

dom0_time = subprocess.check_output(['date', '-u', '+%s'])
self.assertAlmostEquals(int(dom0_time), int(current_time), delta=30)
self.assertAlmostEqual(int(dom0_time), int(current_time), delta=30)

except:
# reset time to some approximation of the real time
Expand Down