Consoles tests API (xml) is incorrectly named
Bug #1083642 reported by
Yolanda Robla
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Fix Released
|
Undecided
|
Yolanda Robla |
Bug Description
There is a bug in the Consoles test API for XML, it's incorrectly named so that test class needs to be renamed.
Changed in nova: | |
assignee: | nobody → Yolanda Robla (yolanda.robla) |
status: | New → In Progress |
Changed in nova: | |
milestone: | none → grizzly-2 |
status: | Fix Committed → Fix Released |
Changed in nova: | |
milestone: | grizzly-2 → 2013.1 |
To post a comment you must log in.
There is a problem with the XML validation:
19:59:49 ======= ======= ======= ======= ======= ======= ======= ======= ======= ======= integrated. test_api_ samples. ConsolesSampleX mlTests. test_get_ vnc_console ------- ------- ------- ------- ------- ------- ------- ------- ------- jenkins/ workspace/ gate-nova- python26/ nova/tests/ integrated/ test_api_ samples. py", line 1632, in test_get_ vnc_console jenkins/ workspace/ gate-nova- python26/ nova/tests/ integrated/ test_api_ samples. py", line 238, in _verify_response something( subs, expected, sample_data) jenkins/ workspace/ gate-nova- python26/ nova/tests/ integrated/ test_api_ samples. py", line 205, in _verify_something data(data) jenkins/ workspace/ gate-nova- python26/ nova/tests/ integrated/ test_api_ samples. py", line 74, in _pretty_data lxml.etree. c:54506) _parseMemoryDoc ument (src/lxml/ lxml.etree. c:82843) _parseDoc (src/lxml/ lxml.etree. c:81641) _BaseParser. _parseDoc (src/lxml/ lxml.etree. c:78311) _ParserContext. _handleParseRes ultDoc (src/lxml/ lxml.etree. c:74567) _handleParseRes ult (src/lxml/ lxml.etree. c:75458) _raiseParseErro r (src/lxml/ lxml.etree. c:74791)
19:59:49 ERROR: nova.tests.
19:59:49 -------
19:59:49 _StringException: Traceback (most recent call last):
19:59:49 File "/home/
19:59:49 subs, response)
19:59:49 File "/home/
19:59:49 self._verify_
19:59:49 File "/home/
19:59:49 result = self._pretty_
19:59:49 File "/home/
19:59:49 xml = etree.XML(data)
19:59:49 File "lxml.etree.pyx", line 2736, in lxml.etree.XML (src/lxml/
19:59:49 File "parser.pxi", line 1578, in lxml.etree.
19:59:49 File "parser.pxi", line 1457, in lxml.etree.
19:59:49 File "parser.pxi", line 965, in lxml.etree.
19:59:49 File "parser.pxi", line 569, in lxml.etree.
19:59:49 File "parser.pxi", line 650, in lxml.etree.
19:59:49 File "parser.pxi", line 590, in lxml.etree.
19:59:49 XMLSyntaxError: EntityRef: expecting ';', line 4, column 93
The problem is caused because there is an & that comes in that URL container and it's making etree crash. I tried to use the atom:link mapping but then i'm having a problem, the validation complains because no nsmap is coming in the response. The response that fails is something like that:
<?xml version='1.0' encoding='UTF-8'?> example. com:6080/ vnc_auto. html?token= f9906a48- b71e-4f18- baca-c987da3ebd b3&title= dafa(75ecef58- 3b8e-4659- ab3b-5501454188 e9)</url>
<console>
<type>novnc</type>
<url>http://
</console>
The & is making that crash. What can we do to allow the test to be passed?