)]}'
{"nova/tests/unit/api/openstack/compute/test_instance_actions.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"cf9b1726ecd8ad662b29424019f58fd24c5ac01d","unresolved":false,"context_lines":[{"line_number":82,"context_line":"    def _get_instance_other_project(self, req):"},{"line_number":83,"context_line":"        context \u003d req.environ[\u0027nova.context\u0027]"},{"line_number":84,"context_line":"        project_id \u003d \u0027%s_unequal\u0027 % context.project_id"},{"line_number":85,"context_line":"        return fake_instance.fake_instance_obj(context, project_id\u003dproject_id)"},{"line_number":86,"context_line":""},{"line_number":87,"context_line":"    def _set_policy_rules(self):"},{"line_number":88,"context_line":"        rules \u003d {\u0027compute:get\u0027: \u0027\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"5a8bc5a2_a5f3c771","line":85,"updated":"2016-09-27 17:28:54.000000000","message":"Is there a reason to need to change this?","commit_id":"4efdd7b337fc602ddf50550d2bcdb3b914ed3a96"},{"author":{"_account_id":16907,"name":"Diana Clarke","email":"diana.joan.clarke@gmail.com","username":"diana-clarke"},"change_message_id":"5816631df2bb67b769e5518976045866bc37e58b","unresolved":false,"context_lines":[{"line_number":82,"context_line":"    def _get_instance_other_project(self, req):"},{"line_number":83,"context_line":"        context \u003d req.environ[\u0027nova.context\u0027]"},{"line_number":84,"context_line":"        project_id \u003d \u0027%s_unequal\u0027 % context.project_id"},{"line_number":85,"context_line":"        return fake_instance.fake_instance_obj(context, project_id\u003dproject_id)"},{"line_number":86,"context_line":""},{"line_number":87,"context_line":"    def _set_policy_rules(self):"},{"line_number":88,"context_line":"        rules \u003d {\u0027compute:get\u0027: \u0027\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"5a8bc5a2_bd4d9f9b","line":85,"in_reply_to":"5a8bc5a2_a5f3c771","updated":"2016-09-27 17:53:28.000000000","message":"Yes, this is the same work around I used in the other patch: mock at the api layer rather than the objects layer.\n\nThat is, mock common.get_instance instead of objects.instance.Instance to avoid the get_minimum_version call in _get_instance.\n\nBoth of these tests set the mock return_value to the output from this helper method which is why this changed when the patch decorators changed.","commit_id":"4efdd7b337fc602ddf50550d2bcdb3b914ed3a96"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"ff586af197cde7d702ef75767db4d972d7181e0d","unresolved":false,"context_lines":[{"line_number":82,"context_line":"    def _get_instance_other_project(self, req):"},{"line_number":83,"context_line":"        context \u003d req.environ[\u0027nova.context\u0027]"},{"line_number":84,"context_line":"        project_id \u003d \u0027%s_unequal\u0027 % context.project_id"},{"line_number":85,"context_line":"        return fake_instance.fake_instance_obj(context, project_id\u003dproject_id)"},{"line_number":86,"context_line":""},{"line_number":87,"context_line":"    def _set_policy_rules(self):"},{"line_number":88,"context_line":"        rules \u003d {\u0027compute:get\u0027: \u0027\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"5a8bc5a2_e055bcfa","line":85,"in_reply_to":"5a8bc5a2_bd4d9f9b","updated":"2016-09-27 17:56:04.000000000","message":"I understand changing the mock from nova.objects.instance.Instance.get_by_uuid to nova.api.openstack.common.get_instance but don\u0027t understand why you needed to start using fake_instance.fake_instance_obj when all you need is a simple fake instance object, which objects.Instance will give you.","commit_id":"4efdd7b337fc602ddf50550d2bcdb3b914ed3a96"}]}
