)]}'
{"trove/tests/unittests/upgrade/test_controller.py":[{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"c1d922d8104823e4f7bdfc3d8d44c9dd48452d19","unresolved":false,"context_lines":[{"line_number":17,"context_line":"from trove.extensions.mgmt.upgrade.models import UpgradeMessageSender"},{"line_number":18,"context_line":"from trove.extensions.mgmt.upgrade.service import UpgradeController"},{"line_number":19,"context_line":"from trove.tests.unittests import trove_testtools"},{"line_number":20,"context_line":"import jsonschema"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"class TestUpgradeController(trove_testtools.TestCase):"}],"source_content_type":"text/x-python","patch_set":1,"id":"1aca2d91_82de926b","line":20,"updated":"2015-05-07 18:26:58.000000000","message":"can we correct the order, this should find place at top as per order","commit_id":"34e6cc20fb45f1fc9578b6bc292c7f8865567107"},{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"5d4654f7ff988c2aa48d1a61fda0f337e89cd0f2","unresolved":false,"context_lines":[{"line_number":17,"context_line":"from trove.extensions.mgmt.upgrade.models import UpgradeMessageSender"},{"line_number":18,"context_line":"from trove.extensions.mgmt.upgrade.service import UpgradeController"},{"line_number":19,"context_line":"from trove.tests.unittests import trove_testtools"},{"line_number":20,"context_line":"import jsonschema"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"class TestUpgradeController(trove_testtools.TestCase):"}],"source_content_type":"text/x-python","patch_set":1,"id":"1aca2d91_f54706ba","line":20,"in_reply_to":"1aca2d91_6c0c5aed","updated":"2015-05-09 16:00:39.000000000","message":"Except it was at the bottom before... I suggest, let\u0027s either stop complaining about the order of imports which does not matter anyways, or let\u0027s fix all files (I guess we will have to find somebody willing to do all this work), enable the hacking rule and force a particular ordering so that this discussion does not have to happen again.","commit_id":"34e6cc20fb45f1fc9578b6bc292c7f8865567107"},{"author":{"_account_id":13355,"name":"Edmond Kotowski","email":"ekotowski@gmail.com","username":"ekotowski"},"change_message_id":"af6bdbe4102ec144eea88fe009ec0e3d61323902","unresolved":false,"context_lines":[{"line_number":17,"context_line":"from trove.extensions.mgmt.upgrade.models import UpgradeMessageSender"},{"line_number":18,"context_line":"from trove.extensions.mgmt.upgrade.service import UpgradeController"},{"line_number":19,"context_line":"from trove.tests.unittests import trove_testtools"},{"line_number":20,"context_line":"import jsonschema"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"class TestUpgradeController(trove_testtools.TestCase):"}],"source_content_type":"text/x-python","patch_set":1,"id":"1aca2d91_6c0c5aed","line":20,"in_reply_to":"1aca2d91_82de926b","updated":"2015-05-08 22:28:52.000000000","message":"Agreed import should not be reordered and placed at the bottom.","commit_id":"34e6cc20fb45f1fc9578b6bc292c7f8865567107"},{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"c1d922d8104823e4f7bdfc3d8d44c9dd48452d19","unresolved":false,"context_lines":[{"line_number":60,"context_line":"        self.assertTrue(validator.is_valid(self.body))"},{"line_number":61,"context_line":""},{"line_number":62,"context_line":"    @patch.object(UpgradeMessageSender, \u0027create\u0027, Mock(return_value\u003dMock()))"},{"line_number":63,"context_line":"    def test_controller_with_no_metadata(self):"},{"line_number":64,"context_line":"        \"\"\""},{"line_number":65,"context_line":"        Test the mock controller w/out metadata"},{"line_number":66,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":1,"id":"1aca2d91_22ba1e0b","line":63,"updated":"2015-05-07 18:26:58.000000000","message":"2 things:\n\n1. you do not need to explicitly return Mock()\n\n2. the function does not absorbs the patched object in the arguments","commit_id":"34e6cc20fb45f1fc9578b6bc292c7f8865567107"},{"author":{"_account_id":10215,"name":"Peter Stachowski","email":"peter@tesora.com","username":"peterstac"},"change_message_id":"163bfe85e9d01cefbbbac72dba1aa40c35073c64","unresolved":false,"context_lines":[{"line_number":60,"context_line":"        self.assertTrue(validator.is_valid(self.body))"},{"line_number":61,"context_line":""},{"line_number":62,"context_line":"    @patch.object(UpgradeMessageSender, \u0027create\u0027, Mock(return_value\u003dMock()))"},{"line_number":63,"context_line":"    def test_controller_with_no_metadata(self):"},{"line_number":64,"context_line":"        \"\"\""},{"line_number":65,"context_line":"        Test the mock controller w/out metadata"},{"line_number":66,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":1,"id":"1aca2d91_4e276064","line":63,"in_reply_to":"1aca2d91_22ba1e0b","updated":"2015-05-08 16:24:51.000000000","message":"1. No, that\u0027s right you don\u0027t.  Mock let\u0027s you do things tonnes of ways.\n\n2. Right again.  If you explicitly pass in a Mock object, then no argument is sent to the method (so the signature doesn\u0027t have to change).  Since the mocked object isn\u0027t needed in the method, it doesn\u0027t need to be sent as an argument.\n\nI\u0027m not sure why the -1?  The code works correctly. So would:\n\n    @patch.object(UpgradeMessageSender, \u0027create\u0027, return_value\u003dMock())\n    def test_controller_with_no_metadata(self, create_mock):\n\nBut I don\u0027t think it\u0027s \u0027better\u0027 (since the mock isn\u0027t used) - just different.","commit_id":"34e6cc20fb45f1fc9578b6bc292c7f8865567107"},{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"3cac8f38d1d90312ddaf7d878a9d26b16a828a9c","unresolved":false,"context_lines":[{"line_number":60,"context_line":"        self.assertTrue(validator.is_valid(self.body))"},{"line_number":61,"context_line":""},{"line_number":62,"context_line":"    @patch.object(UpgradeMessageSender, \u0027create\u0027, Mock(return_value\u003dMock()))"},{"line_number":63,"context_line":"    def test_controller_with_no_metadata(self):"},{"line_number":64,"context_line":"        \"\"\""},{"line_number":65,"context_line":"        Test the mock controller w/out metadata"},{"line_number":66,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":1,"id":"1aca2d91_845f99e4","line":63,"in_reply_to":"1aca2d91_4e276064","updated":"2015-05-08 17:12:46.000000000","message":"It was something new to learn, thanks for clarification.\n\nTried to run after removing the patch.object decorator and it found the good thing :)","commit_id":"34e6cc20fb45f1fc9578b6bc292c7f8865567107"},{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"c1d922d8104823e4f7bdfc3d8d44c9dd48452d19","unresolved":false,"context_lines":[{"line_number":82,"context_line":"            context, instance_id, instance_version, location, metadata)"},{"line_number":83,"context_line":"        self.assertEqual(202, resp.status)"},{"line_number":84,"context_line":""},{"line_number":85,"context_line":"    @patch.object(UpgradeMessageSender, \u0027create\u0027, Mock(return_value\u003dMock()))"},{"line_number":86,"context_line":"    def test_controller_with_metadata(self):"},{"line_number":87,"context_line":"        \"\"\""},{"line_number":88,"context_line":"        Test the mock controller with metadata"}],"source_content_type":"text/x-python","patch_set":1,"id":"1aca2d91_a244ee1a","line":85,"updated":"2015-05-07 18:26:58.000000000","message":"Same as above","commit_id":"34e6cc20fb45f1fc9578b6bc292c7f8865567107"},{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"c1d922d8104823e4f7bdfc3d8d44c9dd48452d19","unresolved":false,"context_lines":[{"line_number":112,"context_line":"        self.assertEqual(202, resp.status)"},{"line_number":113,"context_line":""},{"line_number":114,"context_line":"    @patch.object(UpgradeMessageSender, \u0027create\u0027, Mock(return_value\u003dMock()))"},{"line_number":115,"context_line":"    def test_controller_with_empty_metadata(self):"},{"line_number":116,"context_line":"        \"\"\""},{"line_number":117,"context_line":"        Test the mock controller with metadata"},{"line_number":118,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":1,"id":"1aca2d91_824c5243","line":115,"updated":"2015-05-07 18:26:58.000000000","message":"Same as above","commit_id":"34e6cc20fb45f1fc9578b6bc292c7f8865567107"}]}
