)]}'
{"novaclient/tests/functional/v2/legacy/test_consoles.py":[{"author":{"_account_id":679,"name":"Kevin L. Mitchell","email":"klmitch@mit.edu","username":"klmitch"},"change_message_id":"270d0fd6d32d69de92cb19dd3cdb9110633a4011","unresolved":false,"context_lines":[{"line_number":13,"context_line":""},{"line_number":14,"context_line":"from novaclient.tests.functional import base"},{"line_number":15,"context_line":"from novaclient.v2 import shell"},{"line_number":16,"context_line":"from tempest_lib import exceptions"},{"line_number":17,"context_line":""},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"class TestConsolesNovaClient(base.ClientTestBase):"}],"source_content_type":"text/x-python","patch_set":3,"id":"7a2fa921_99533b6b","line":16,"updated":"2015-10-08 15:41:26.000000000","message":"This is a third-party import, which should be in a section by itself, preceding the novaclient imports…","commit_id":"d1af30265cc130becea382d55845348d1929817f"}],"novaclient/tests/functional/v2/test_consoles.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"ecfb97c8a7145bf63b5f498485420659c865a715","unresolved":false,"context_lines":[{"line_number":18,"context_line":"class TestConsolesNovaClient(base.ClientTestBase):"},{"line_number":19,"context_line":"    \"\"\"Consoles functional tests.\"\"\""},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"    COMPUTE_API_VERSION \u003d \"2.latest\""},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"    def _create_server(self):"},{"line_number":24,"context_line":"        name \u003d self.name_generate(prefix\u003d\u0027server\u0027)"}],"source_content_type":"text/x-python","patch_set":2,"id":"7a2fa921_93a9367e","line":21,"updated":"2015-10-06 21:03:55.000000000","message":"I think this needs to be 2.6 since we\u0027re testing the boundary where 2.6 has the change.  Or maybe this should be 2.1 depending on how you implement this, because you also need a version of the test that hits the lower bound, generally one test extends the other, like this:\n\nhttps://github.com/openstack/python-novaclient/blob/master/novaclient/tests/functional/v2/test_fixedips.py\n\nThat tests v2.4 and the base class tests v2.1.  You need something like that for consoles so we have lower and upper bounds functional test coverage.\n\nWe don\u0027t need to get anything back from the console, we just need to make sure that the API request is OK.","commit_id":"ee6f75949a0ff355f0e5263d5aaeec040d642021"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"40723dd6802e36903508e1be15516e66d19d9b0c","unresolved":false,"context_lines":[{"line_number":39,"context_line":""},{"line_number":40,"context_line":"    def test_spice_console_get(self, expect_reserved\u003dFalse):"},{"line_number":41,"context_line":"        server \u003d self._create_server()"},{"line_number":42,"context_line":"        table \u003d self.nova(\u0027get-spice-console %s spice-html5\u0027 % server.id)"},{"line_number":43,"context_line":"        _type \u003d self._get_column_value_from_single_row_table(table, \u0027Type\u0027)"},{"line_number":44,"context_line":"        url \u003d self._get_column_value_from_single_row_table(table, \u0027Url\u0027)"},{"line_number":45,"context_line":"        self.assertEqual(_type, \u0027spice-html5\u0027)"}],"source_content_type":"text/x-python","patch_set":2,"id":"7a2fa921_d369ee26","line":42,"updated":"2015-10-06 21:07:44.000000000","message":"Since spice isn\u0027t enabled in devstack, this isn\u0027t going to work.  Same is true for the others.\n\nTherefore, I think it\u0027s OK to add a handler for the error as long as we parse stderr and make sure the output is what we\u0027d expect, like this for spice:\n\n\"Unavailable console type spice-html5\" in stederr","commit_id":"ee6f75949a0ff355f0e5263d5aaeec040d642021"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"3720c96eb36c39687928736a82443668bdbe5d2d","unresolved":false,"context_lines":[{"line_number":39,"context_line":""},{"line_number":40,"context_line":"    def test_spice_console_get(self, expect_reserved\u003dFalse):"},{"line_number":41,"context_line":"        server \u003d self._create_server()"},{"line_number":42,"context_line":"        table \u003d self.nova(\u0027get-spice-console %s spice-html5\u0027 % server.id)"},{"line_number":43,"context_line":"        _type \u003d self._get_column_value_from_single_row_table(table, \u0027Type\u0027)"},{"line_number":44,"context_line":"        url \u003d self._get_column_value_from_single_row_table(table, \u0027Url\u0027)"},{"line_number":45,"context_line":"        self.assertEqual(_type, \u0027spice-html5\u0027)"}],"source_content_type":"text/x-python","patch_set":2,"id":"7a2fa921_c514c145","line":42,"in_reply_to":"7a2fa921_d369ee26","updated":"2015-10-06 21:19:07.000000000","message":"Probably even better is just asserting a 400 rather than a 404.  Parsing the error message is brittle in case that changes on the server side.\n\nIn the bug they are getting a 404 because we\u0027re calling the wrong API after v2.6:\n\n\"ERROR (NotFound): The resource could not be found. (HTTP 404) (Request-ID: req-6f260624-56ad-45fd-aa21-f86fb2c541d1)\"\n\nSo just making sure that we get 400 back and not 404 is probably sufficient for this test.  If there isn\u0027t an error, it means the console is enabled and then doing what you have here is OK, but I wouldn\u0027t rely on it in all devstack configs.","commit_id":"ee6f75949a0ff355f0e5263d5aaeec040d642021"}]}
