[Kimchi-devel] [PATCH 0/6] New MockModel \o/

Aline Manera alinefm at linux.vnet.ibm.com
Fri Nov 14 13:57:23 UTC 2014


Thanks for checking, Daniel!

I haven't gotten this error because I have an user named "admin" in my 
system =)
I will update it and resend.

On 11/13/2014 03:14 PM, Daniel Henrique Barboza wrote:
> After testing the patch set I got only one error in the following test:
>
> 1.
>     ======================================================================
> 2.
>     ERROR: test_nonroot_access (test_authorization.AuthorizationTests)
> 3.
>     ----------------------------------------------------------------------
> 4.
>     Traceback (most recent call last):
> 5.
>       File "test_authorization.py", line 124, in test_nonroot_access
> 6.
>     'groups': []})
> 7.
>       File
>     "/home/danielhb/kimchi/kimchi-upstream/src/kimchi/model/vms.py",
>     line 277, in update
> 8.
>     self._live_vm_update(dom, params)
> 9.
>       File
>     "/home/danielhb/kimchi/kimchi-upstream/src/kimchi/model/vms.py",
>     line 668, in _live_vm_update
>10.
>     self._vm_update_access_metadata(dom, params)
>11.
>       File
>     "/home/danielhb/kimchi/kimchi-upstream/src/kimchi/model/vms.py",
>     line 556, in _vm_update_access_metadata
>12.
>     {'users': ", ".join(invalid_users)})
>13.
>     InvalidParameter: KCHVM0027E: User(s) 'admin' do not exist
>
>
> My guess is that the user 'admin' is being passed forward to the 
> _vm_update method while I do not
> have the 'admin' user in my system.
>
>
> Thanks!
>
> On 11/11/2014 06:46 PM, Aline Manera wrote:
>> Yeap! Finally it is done!
>>
>> The new MockModel uses Model with the 'test:///default' URI.
>> I also needed to update some tests cases and the run_tests.sh.in scripts as
>> the new MockModel overrides some Model functions, the test_model.py must be the
>> first test to be run.
>>
>> But there are one test that is still failing:
>>
>> ======================================================================
>> FAIL: test_edit_vm (test_rest.RestTests)
>> ----------------------------------------------------------------------
>> Traceback (most recent call last):
>>    File "test_rest.py", line 248, in test_edit_vm
>>      self.assertEquals('123456', info["graphics"]["passwd"])
>> AssertionError: '123456' != u'abcdef'
>>
>> I could not identify the reason yet, as the same test runs fine when I only run
>> test_rest.py. I suspect it is a override issue.
>> While I am investigating it I decided to send the patches to collect feedbacks
>> soon.
>>
>> Aline Manera (6):
>>    Re-raise the original exception when creating a new Template
>>    Use objectify to Remove metadata namespace
>>    Check currentMemory exists prior to remote its XML node
>>    Ensure the guest volume exists to remove it
>>    Pass libvirt connection as CapabilitiesModel parameter
>>    MockModel refactor: Create MockModel based on Model("test:///default")
>>
>>   src/kimchi/mockmodel.py            | 1769 +++++++-----------------------------
>>   src/kimchi/model/host.py           |    3 +-
>>   src/kimchi/model/storagepools.py   |    2 +-
>>   src/kimchi/model/storagetargets.py |    2 +-
>>   src/kimchi/model/templates.py      |    5 +-
>>   src/kimchi/model/utils.py          |   37 +-
>>   src/kimchi/model/vmhostdevs.py     |    3 +-
>>   src/kimchi/model/vmifaces.py       |    5 +-
>>   src/kimchi/model/vms.py            |   44 +-
>>   src/kimchi/model/vmstorages.py     |   16 +-
>>   src/kimchi/vmtemplate.py           |    9 +-
>>   tests/run_tests.sh.in              |   18 +-
>>   tests/test_authorization.py        |   25 +-
>>   tests/test_mockmodel.py            |   60 +-
>>   tests/test_rest.py                 |  254 +++---
>>   15 files changed, 565 insertions(+), 1687 deletions(-)
>>
>
>
>
> _______________________________________________
> Kimchi-devel mailing list
> Kimchi-devel at ovirt.org
> http://lists.ovirt.org/mailman/listinfo/kimchi-devel

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ovirt.org/pipermail/kimchi-devel/attachments/20141114/bcd7fa4a/attachment.html>


More information about the Kimchi-devel mailing list