Bug 1315487 - Tempest fails two tempest.api.baremetal.* tests when Ironic service returns unicode strings
Summary: Tempest fails two tempest.api.baremetal.* tests when Ironic service returns u...
Keywords:
Status: CLOSED INSUFFICIENT_DATA
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-tempest
Version: 7.0 (Kilo)
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: 8.0 (Liberty)
Assignee: Daniel Mellado
QA Contact: tkammer
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-03-07 21:37 UTC by Harry Rybacki
Modified: 2017-10-09 13:06 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-03-10 07:25:26 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Harry Rybacki 2016-03-07 21:37:56 UTC
Description of problem:
Tempest is failing two api.baremetal.* tests when Ironic is returning unicode strings.

Version-Release number of selected component (if applicable):
- Pinned release of tempest[1]
- Custom fork (from above pinned release) that removes tempest dependency on Cinder to allow for testing against the undercloud[2]

How reproducible:
Relatively easy


Steps to Reproduce:
1. Using rdo-manager install an undercloud
2. On the undercloud, clone[2]
3. Ensure that the fake driver is enabled for Ironic `ironic driver-list`
4. Run baremetal tests: `source /home/stack/stackrc; cd /home/stack/tempest && tools/run-tests.sh --skip-file /home/stack/skipfile tempest\.api\.baremetal.*`

Actual results:

baremetal.admin.test_list_ports and baremetal.test_list_ports_details fail[3] 

<output omitted>
...
    Traceback (most recent call last):
      File "/home/stack/tempest/tempest/api/baremetal/admin/test_ports.py", line 145, in test_list_ports_details
        port['links'][0]['href'])
      File "/home/stack/tempest/tempest/api/baremetal/admin/base.py", line 211, in validate_self_link
        self.assertEqual(expected_link, link)
      File "/usr/lib/python2.7/site-packages/testtools/testcase.py", line 348, in assertEqual
        self.assertThat(observed, matcher, message)
      File "/usr/lib/python2.7/site-packages/testtools/testcase.py", line 433, in assertThat
        raise mismatch_error
    MismatchError: !=:
    reference = 'http://192.0.2.1:6385//v1/ports/96eb8bd4-e8b1-45f9-99e6-21e7d3b1cb39'
    actual    = u'http://192.0.2.1:6385/v1/ports/96eb8bd4-e8b1-45f9-99e6-21e7d3b1cb39'
...
<output omitted>
======
Totals
======
Ran: 69 tests in 19.0000 sec.
 - Passed: 65
 - Skipped: 2
 - Expected Fail: 0
 - Unexpected Success: 0
 - Failed: 2

Expected results:
...<output omitted>
======
Totals
======
Ran: 69 tests in 19.0000 sec.
 - Passed: 67
 - Skipped: 2
 - Expected Fail: 0
 - Unexpected Success: 0
 - Failed: 0

Additional info:

[1] - https://github.com/redhat-openstack/tempest/releases/tag/openstack-tempest-kilo-20151020
[2] - https://github.com/harryrybacki/tempest/tree/tempest_undercloud_testing
[3] - http://fpaste.org/335349/57385679/


Note You need to log in before you can comment on or make changes to this bug.