heatclient.tests.test_template_utils.ShellEnvironmentTest.test_process_multiple_environments_default_resources fails in 0.2.12 under python 3.3

Bug #1375051 reported by Alex Brandt
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
python-heatclient
Incomplete
Undecided
Unassigned

Bug Description

Looks like the transition in python 3.3 to byte arrays seems to throw off this particular test:

FAIL: heatclient.tests.test_template_utils.ShellEnvironmentTest.test_process_multiple_environments_default_resources
tags: worker-0
----------------------------------------------------------------------
traceback-1: {{{
Traceback (most recent call last):
  File "/usr/lib64/python3.3/site-packages/mox3/mox.py", line 289, in VerifyAll
    mock_obj._Verify()
  File "/usr/lib64/python3.3/site-packages/mox3/mox.py", line 543, in _Verify
    raise ExpectedMethodCallsError(self._expected_calls_queue)
mox3.mox.ExpectedMethodCallsError: Verify: Expected methods never called:
  0. function.__call__('file:///home/b/b.yaml') -> <_io.BytesIO object at 0x7fe73ce300b8>
  1. function.__call__('file:///home/my/dir/env2.yaml') -> <_io.BytesIO object at 0x7fe73ce307a0>
  2. function.__call__('file:///home/b/a.yaml') -> <_io.BytesIO object at 0x7fe73ce30600>
  3. function.__call__('file:///home/b/b.yaml') -> <_io.BytesIO object at 0x7fe73ce30d50>
}}}

Traceback (most recent call last):
  File "./heatclient/tests/test_template_utils.py", line 269, in test_process_multiple_environments_default_resources
    [env_file1, env_file2])
  File "./heatclient/common/template_utils.py", line 182, in process_multiple_environments_and_files
    template_url)
  File "./heatclient/common/template_utils.py", line 209, in process_environment_and_files
    env_base_url)
  File "./heatclient/common/template_utils.py", line 236, in resolve_environment_urls
    res_dict, files, res_base_url, ignore_if, file_is_template=True)
  File "./heatclient/common/template_utils.py", line 127, in get_file_contents
    template_url=str_url, files=files)[1]
  File "./heatclient/common/template_utils.py", line 39, in get_template_contents
    tpl = request.urlopen(template_url).read()
  File "/usr/lib64/python3.3/site-packages/mox3/mox.py", line 814, in __call__
    return mock_method(*params, **named_params)
  File "/usr/lib64/python3.3/site-packages/mox3/mox.py", line 1111, in __call__
    expected_method = self._VerifyMethodCall()
  File "/usr/lib64/python3.3/site-packages/mox3/mox.py", line 1178, in _VerifyMethodCall
    raise UnexpectedMethodCallError(self, expected)
mox3.mox.UnexpectedMethodCallError: Unexpected method call. unexpected:- expected:+
- function.__call__('file:///home/b/b.yaml') -> None
+ function.__call__('file:///home/b/a.yaml') -> <_io.BytesIO object at 0x7fe73ce302c0>

Revision history for this message
Steve Baker (steve-stevebaker) wrote :

This test is working in the python 3.4 gate job. Is this still an issue for you?

Changed in python-heatclient:
status: New → Incomplete
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.