summaryrefslogtreecommitdiff
path: root/tests/qemu-iotests/163
diff options
context:
space:
mode:
authorMax Reitz <mreitz@redhat.com>2018-10-22 14:53:02 +0100
committerEduardo Habkost <ehabkost@redhat.com>2018-10-30 21:11:52 -0300
commit9a3a9a636eaf207816891f504b569b8d674987aa (patch)
treed36aa86b2797ee390d8b2b3aaedef2806ec9b729 /tests/qemu-iotests/163
parent8eb5e6746feaf9e021b69ea2521899f8dc889033 (diff)
downloadqemu-9a3a9a636eaf207816891f504b569b8d674987aa.zip
iotests: Use // for Python integer division
In Python 3, / is always a floating-point division. We usually do not want this, and as Python 2.7 understands // as well, change all integer divisions to use that. Signed-off-by: Max Reitz <mreitz@redhat.com> Reviewed-by: Eduardo Habkost <ehabkost@redhat.com> Reviewed-by: Cleber Rosa <crosa@redhat.com> Message-Id: <20181022135307.14398-5-mreitz@redhat.com> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
Diffstat (limited to 'tests/qemu-iotests/163')
-rwxr-xr-xtests/qemu-iotests/1632
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/qemu-iotests/163 b/tests/qemu-iotests/163
index 403842354e..5fd424761b 100755
--- a/tests/qemu-iotests/163
+++ b/tests/qemu-iotests/163
@@ -38,7 +38,7 @@ class ShrinkBaseClass(iotests.QMPTestCase):
entry_bits = 3
entry_size = 1 << entry_bits
l1_mask = 0x00fffffffffffe00
- div_roundup = lambda n, d: (n + d - 1) / d
+ div_roundup = lambda n, d: (n + d - 1) // d
def split_by_n(data, n):
for x in xrange(0, len(data), n):