On 27.02.2013 [22:52:19 -0300], Lucas Meneghel Rodrigues wrote:
> On 02/27/2013 05:54 PM, Lucas Meneghel Rodrigues wrote:
> >Great, looks good.
> 
> Looks good, but the unittests will have to be adapted:

I'll fix them up tomorrow and send out an updated patch. Sorry, I meant
for this to be an RFC too!

-Nish

> [lmr@thinkpad-t420s autotest]$ cli/topic_common_unittest.py
> ..........FEEEF.FEEF.F..................................................
> ======================================================================
> ERROR: test_parse_add_on_first (__main__.atest_unittest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "cli/topic_common_unittest.py", line 509, in test_parse_add_on_first
>     self.atest.parser.add_option('-U', '--ulist', type='string')
>   File "/usr/lib64/python2.7/optparse.py", line 1020, in add_option
>     self._check_conflict(option)
>   File "/usr/lib64/python2.7/optparse.py", line 995, in _check_conflict
>     option)
> OptionConflictError: option -U/--ulist: conflicting option string(s): -U
> 
> ======================================================================
> ERROR: test_parse_add_on_second (__main__.atest_unittest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "cli/topic_common_unittest.py", line 546, in
> test_parse_add_on_second
>     self.atest.parser.add_option('-U', '--ulist', type='string')
>   File "/usr/lib64/python2.7/optparse.py", line 1020, in add_option
>     self._check_conflict(option)
>   File "/usr/lib64/python2.7/optparse.py", line 995, in _check_conflict
>     option)
> OptionConflictError: option -U/--ulist: conflicting option string(s): -U
> 
> ======================================================================
> ERROR: test_parse_all_opts (__main__.atest_unittest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "cli/topic_common_unittest.py", line 583, in test_parse_all_opts
>     self.atest.parser.add_option('-U', '--ulist', type='string')
>   File "/usr/lib64/python2.7/optparse.py", line 1020, in add_option
>     self._check_conflict(option)
>   File "/usr/lib64/python2.7/optparse.py", line 995, in _check_conflict
>     option)
> OptionConflictError: option -U/--ulist: conflicting option string(s): -U
> 
> ======================================================================
> ERROR: test_parse_no_add_on_2 (__main__.atest_unittest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "cli/topic_common_unittest.py", line 618, in test_parse_no_add_on_2
>     self.atest.parser.add_option('-U', '--ulist', type='string')
>   File "/usr/lib64/python2.7/optparse.py", line 1020, in add_option
>     self._check_conflict(option)
>   File "/usr/lib64/python2.7/optparse.py", line 995, in _check_conflict
>     option)
> OptionConflictError: option -U/--ulist: conflicting option string(s): -U
> 
> ======================================================================
> ERROR: test_parse_no_flist_add_on (__main__.atest_unittest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "cli/topic_common_unittest.py", line 650, in
> test_parse_no_flist_add_on
>     self.atest.parser.add_option('-U', '--ulist', type='string')
>   File "/usr/lib64/python2.7/optparse.py", line 1020, in add_option
>     self._check_conflict(option)
>   File "/usr/lib64/python2.7/optparse.py", line 995, in _check_conflict
>     option)
> OptionConflictError: option -U/--ulist: conflicting option string(s): -U
> 
> ======================================================================
> FAIL: test_parse_add_on (__main__.atest_unittest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "cli/topic_common_unittest.py", line 475, in test_parse_add_on
>     'debug': False}, options)
> AssertionError: {'parse': True, 'web_server': 'fooweb',
> 'kill_on_failure': True, 'verbose': False, 'parse_delim': '|',
> 'mlist': '/tmp/_autotmp_Lcca2Acli_mock', 'debug': False} != <Values
> at 0xde8dd0: {'username': None, 'mlist':
> '/tmp/_autotmp_Lcca2Acli_mock', 'parse_delim': '|',
> 'kill_on_failure': True, 'verbose': False, 'web_server': 'fooweb',
> 'parse': True, 'debug': False}>
> 
> ======================================================================
> FAIL: test_parse_all_set (__main__.atest_unittest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "cli/topic_common_unittest.py", line 759, in test_parse_all_set
>     'debug': True}, options)
> AssertionError: {'web_server': 'fooweb', 'kill_on_failure': True,
> 'verbose': True, 'parse_delim': '?', 'parse': True, 'debug': True}
> != <Values at 0xdfd560: {'username': None, 'parse_delim': '?',
> 'kill_on_failure': True, 'verbose': True, 'web_server': 'fooweb',
> 'parse': True, 'debug': True}>
> 
> ======================================================================
> FAIL: test_parse_no_add_on (__main__.atest_unittest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "cli/topic_common_unittest.py", line 497, in test_parse_no_add_on
>     'debug': True}, options)
> AssertionError: {'parse': True, 'web_server': 'fooweb',
> 'kill_on_failure': True, 'verbose': False, 'parse_delim': '|',
> 'mlist': '/tmp/_autotmp_e9VtlQcli_mock', 'debug': True} != <Values
> at 0xe89368: {'username': None, 'mlist':
> '/tmp/_autotmp_e9VtlQcli_mock', 'parse_delim': '|',
> 'kill_on_failure': True, 'verbose': False, 'web_server': 'fooweb',
> 'parse': True, 'debug': True}>
> 
> ======================================================================
> FAIL: test_parse_no_flist_no_add_on (__main__.atest_unittest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "cli/topic_common_unittest.py", line 696, in
> test_parse_no_flist_no_add_on
>     'debug': False}, options)
> AssertionError: {'parse': False, 'web_server': None,
> 'kill_on_failure': True, 'user': 'myuser,youruser', 'debug': False,
> 'verbose': False, 'parse_delim': '|', 'acl': 'acl1,acl2'} != <Values
> at 0xe8b248: {'username': None, 'parse_delim': '|',
> 'kill_on_failure': True, 'verbose': False, 'web_server': None,
> 'acl': 'acl1,acl2', 'parse': False, 'user': 'myuser,youruser',
> 'debug': False}>
> 
> ======================================================================
> FAIL: test_parse_req_items_ok (__main__.atest_unittest)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "cli/topic_common_unittest.py", line 716, in test_parse_req_items_ok
>     'debug': False}, options)
> AssertionError: {'web_server': None, 'kill_on_failure': False,
> 'verbose': False, 'parse_delim': '|', 'parse': False, 'user':
> 'myuser,youruser', 'debug': False} != <Values at 0xe8b908:
> {'username': None, 'parse_delim': '|', 'kill_on_failure': False,
> 'verbose': False, 'web_server': None, 'parse': False, 'user':
> 'myuser,youruser', 'debug': False}>
> 
> ----------------------------------------------------------------------
> Ran 72 tests in 0.043s
> 
> FAILED (failures=5, errors=5)
> 
> I'm not applying this for now. Tomorrow I'll see about fixing the unittests.
> 

_______________________________________________
Autotest-kernel mailing list
[email protected]
https://www.redhat.com/mailman/listinfo/autotest-kernel

Reply via email to