)]}'
{"octavia/tests/functional/amphorae/backend/agent/api_server/test_server.py":[{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"6997e14aa4a9d5719e04ef9c0bf4a95a0e87551e","unresolved":false,"context_lines":[{"line_number":441,"context_line":"            handle.write.assert_called_once_with(six.b(\u0027TestTest\u0027))"},{"line_number":442,"context_line":"            mock_chmod.assert_called_once_with(handle.fileno(), 0o600)"},{"line_number":443,"context_line":""},{"line_number":444,"context_line":"        mock_exists.side_effect \u003d [False]"},{"line_number":445,"context_line":"        m \u003d mock.mock_open()"},{"line_number":446,"context_line":""},{"line_number":447,"context_line":"        with mock.patch.object(builtins, \u0027open\u0027, m):"}],"source_content_type":"text/x-python","patch_set":3,"id":"dae33548_5b7bdb29","line":444,"updated":"2016-02-19 02:45:27.000000000","message":"In the case that it\u0027s always the same value, instead of side_effect it would just be mock_exists.return_value \u003d False","commit_id":"cf645e0f0f4a8b03ed8d81162c7b1191b4765166"},{"author":{"_account_id":8686,"name":"Wang Bo","email":"bo.wang@easystack.cn","username":"wangbo"},"change_message_id":"ce2d83b384da0e0a23c44681cc15b0a183a72980","unresolved":false,"context_lines":[{"line_number":441,"context_line":"            handle.write.assert_called_once_with(six.b(\u0027TestTest\u0027))"},{"line_number":442,"context_line":"            mock_chmod.assert_called_once_with(handle.fileno(), 0o600)"},{"line_number":443,"context_line":""},{"line_number":444,"context_line":"        mock_exists.side_effect \u003d [False]"},{"line_number":445,"context_line":"        m \u003d mock.mock_open()"},{"line_number":446,"context_line":""},{"line_number":447,"context_line":"        with mock.patch.object(builtins, \u0027open\u0027, m):"}],"source_content_type":"text/x-python","patch_set":3,"id":"dae33548_1b34b348","line":444,"in_reply_to":"dae33548_5b7bdb29","updated":"2016-02-19 02:51:02.000000000","message":"Yes, that make sense.\n\nDone in patch set 4.","commit_id":"cf645e0f0f4a8b03ed8d81162c7b1191b4765166"},{"author":{"_account_id":8686,"name":"Wang Bo","email":"bo.wang@easystack.cn","username":"wangbo"},"change_message_id":"46321d926aa74cf2cb6966c15fc6c2ca0df4ccac","unresolved":false,"context_lines":[{"line_number":422,"context_line":"    def test_upload_certificate_md5(self, mock_makedir, mock_chmod,"},{"line_number":423,"context_line":"                                    mock_exists):"},{"line_number":424,"context_line":"        # wrong file name"},{"line_number":425,"context_line":"        mock_exists.side_effect \u003d [True]"},{"line_number":426,"context_line":"        rv \u003d self.app.put(\u0027/\u0027 + api_server.VERSION +"},{"line_number":427,"context_line":"                          \u0027/listeners/123/certificates/test.bla\u0027,"},{"line_number":428,"context_line":"                          data\u003d\u0027TestTest\u0027)"}],"source_content_type":"text/x-python","patch_set":5,"id":"bae84128_5d5e2c46","side":"PARENT","line":425,"range":{"start_line":425,"start_character":31,"end_line":425,"end_character":32},"updated":"2016-02-19 12:01:06.000000000","message":"remove this line. Because code will never run into test if directory exists when to test 400 bad request.","commit_id":"c1b1f6ed85103bc359f1a9b6a216918328c758b1"},{"author":{"_account_id":8686,"name":"Wang Bo","email":"bo.wang@easystack.cn","username":"wangbo"},"change_message_id":"46321d926aa74cf2cb6966c15fc6c2ca0df4ccac","unresolved":false,"context_lines":[{"line_number":427,"context_line":"                          data\u003d\u0027TestTest\u0027)"},{"line_number":428,"context_line":"        self.assertEqual(400, rv.status_code)"},{"line_number":429,"context_line":""},{"line_number":430,"context_line":"        mock_exists.return_value \u003d True"},{"line_number":431,"context_line":"        m \u003d mock.mock_open()"},{"line_number":432,"context_line":""},{"line_number":433,"context_line":"        with mock.patch.object(builtins, \u0027open\u0027, m):"}],"source_content_type":"text/x-python","patch_set":5,"id":"bae84128_00aa7bd4","line":430,"range":{"start_line":430,"start_character":8,"end_line":430,"end_character":39},"updated":"2016-02-19 12:01:06.000000000","message":"use mock_exists.return_value instead of side_effect for each situation:\n1. file exists, update it","commit_id":"c31781b122ad5bfd3f6ad5b6036aed3dfc2a4869"},{"author":{"_account_id":8686,"name":"Wang Bo","email":"bo.wang@easystack.cn","username":"wangbo"},"change_message_id":"46321d926aa74cf2cb6966c15fc6c2ca0df4ccac","unresolved":false,"context_lines":[{"line_number":440,"context_line":"            handle.write.assert_called_once_with(six.b(\u0027TestTest\u0027))"},{"line_number":441,"context_line":"            mock_chmod.assert_called_once_with(handle.fileno(), 0o600)"},{"line_number":442,"context_line":""},{"line_number":443,"context_line":"        mock_exists.return_value \u003d False"},{"line_number":444,"context_line":"        m \u003d mock.mock_open()"},{"line_number":445,"context_line":""},{"line_number":446,"context_line":"        with mock.patch.object(builtins, \u0027open\u0027, m):"}],"source_content_type":"text/x-python","patch_set":5,"id":"bae84128_4093e3a3","line":443,"range":{"start_line":443,"start_character":8,"end_line":443,"end_character":40},"updated":"2016-02-19 12:01:06.000000000","message":"2. file does not exist, create it.","commit_id":"c31781b122ad5bfd3f6ad5b6036aed3dfc2a4869"}],"octavia/tests/functional/amphorae/backend/agent/api_server/test_server_sysvinit.py":[{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"6997e14aa4a9d5719e04ef9c0bf4a95a0e87551e","unresolved":false,"context_lines":[{"line_number":447,"context_line":"            handle.write.assert_called_once_with(six.b(\u0027TestTest\u0027))"},{"line_number":448,"context_line":"            mock_chmod.assert_called_once_with(handle.fileno(), 0o600)"},{"line_number":449,"context_line":""},{"line_number":450,"context_line":"        mock_exists.side_effect \u003d [False]"},{"line_number":451,"context_line":"        m \u003d mock.mock_open()"},{"line_number":452,"context_line":""},{"line_number":453,"context_line":"        with mock.patch.object(builtins, \u0027open\u0027, m):"}],"source_content_type":"text/x-python","patch_set":3,"id":"dae33548_3b78972b","line":450,"updated":"2016-02-19 02:45:27.000000000","message":"Same as the other file","commit_id":"cf645e0f0f4a8b03ed8d81162c7b1191b4765166"},{"author":{"_account_id":8686,"name":"Wang Bo","email":"bo.wang@easystack.cn","username":"wangbo"},"change_message_id":"ce2d83b384da0e0a23c44681cc15b0a183a72980","unresolved":false,"context_lines":[{"line_number":447,"context_line":"            handle.write.assert_called_once_with(six.b(\u0027TestTest\u0027))"},{"line_number":448,"context_line":"            mock_chmod.assert_called_once_with(handle.fileno(), 0o600)"},{"line_number":449,"context_line":""},{"line_number":450,"context_line":"        mock_exists.side_effect \u003d [False]"},{"line_number":451,"context_line":"        m \u003d mock.mock_open()"},{"line_number":452,"context_line":""},{"line_number":453,"context_line":"        with mock.patch.object(builtins, \u0027open\u0027, m):"}],"source_content_type":"text/x-python","patch_set":3,"id":"dae33548_db5ecb78","line":450,"in_reply_to":"dae33548_3b78972b","updated":"2016-02-19 02:51:02.000000000","message":"Done","commit_id":"cf645e0f0f4a8b03ed8d81162c7b1191b4765166"}]}
