[ovirt-devel] System tests failure (wrong test code?)

Nir Soffer nsoffer at redhat.com
Thu Mar 16 08:46:18 UTC 2017


If found this error in system tests - looks like wrong assert - code should
check
if disk is not None before checking state.

I'm not sure who is the owner of this test, so posting here.

*08:28:05*   # snapshots_merge: *08:28:31* Unhandled exception in
<function <lambda> at 0x276a5f0>*08:28:31* Traceback (most recent call
last):*08:28:31*   File
"/usr/lib/python2.7/site-packages/ovirtlago/testlib.py", line 217, in
assert_equals_within*08:28:31*     res = func()*08:28:31*   File
"/home/jenkins/workspace/ovirt-system-tests_manual/ovirt-system-tests/basic-suite-master/test-scenarios/004_basic_sanity.py",
line 466, in <lambda>*08:28:31*
api.vms.get(VM0_NAME).disks.get(disk_name).status.state ==
'ok'*08:28:31* AttributeError: 'NoneType' object has no attribute
'state'*08:28:31* Error while running thread*08:28:31* Traceback (most
recent call last):*08:28:31*   File
"/usr/lib/python2.7/site-packages/lago/utils.py", line 57, in
_ret_via_queue*08:28:31*     queue.put({'return': func()})*08:28:31*
File "/home/jenkins/workspace/ovirt-system-tests_manual/ovirt-system-tests/basic-suite-master/test-scenarios/004_basic_sanity.py",
line 465, in snapshot_live_merge*08:28:31*     lambda:*08:28:31*
File "/usr/lib/python2.7/site-packages/ovirtlago/testlib.py", line
264, in assert_true_within_long*08:28:31*
assert_equals_within_long(func, True, allowed_exceptions)*08:28:31*
File "/usr/lib/python2.7/site-packages/ovirtlago/testlib.py", line
251, in assert_equals_within_long*08:28:31*     func, value,
LONG_TIMEOUT, allowed_exceptions=allowed_exceptions*08:28:31*   File
"/usr/lib/python2.7/site-packages/ovirtlago/testlib.py", line 217, in
assert_equals_within*08:28:31*     res = func()*08:28:31*   File
"/home/jenkins/workspace/ovirt-system-tests_manual/ovirt-system-tests/basic-suite-master/test-scenarios/004_basic_sanity.py",
line 466, in <lambda>*08:28:31*
api.vms.get(VM0_NAME).disks.get(disk_name).status.state ==
'ok'*08:28:31* AttributeError: 'NoneType' object has no attribute
'state'
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ovirt.org/pipermail/devel/attachments/20170316/e819e842/attachment-0001.html>


More information about the Devel mailing list