)]}'
{"openstack_auth/tests/unit/test_auth.py":[{"author":{"_account_id":841,"name":"Akihiro Motoki","email":"amotoki@gmail.com","username":"amotoki"},"change_message_id":"a0a3669fcf358b705888842bd02c41948a6de6a8","unresolved":false,"context_lines":[{"line_number":637,"context_line":"        # POST to the page to log in."},{"line_number":638,"context_line":"        response \u003d self.client.post(url, form_data)"},{"line_number":639,"context_line":"        self.assertRedirects(response, settings.LOGIN_REDIRECT_URL)"},{"line_number":640,"context_line":""},{"line_number":641,"context_line":"        mock_token.assert_has_calls(["},{"line_number":642,"context_line":"            mock.call("},{"line_number":643,"context_line":"                auth_url\u003dsettings.OPENSTACK_KEYSTONE_URL,"}],"source_content_type":"text/x-python","patch_set":2,"id":"1fa4df85_93596c8f","line":640,"updated":"2020-03-03 00:23:13.000000000","message":"When assert_has_calls() is used, we also check the number of calls because assert_has_calls() succeeds when a specified expected call list is a subset of mock_calls. I believe it is better to ensure all calls are checked.\n\nIn this case, call_count cannot be used as it checks method calls of the instantiated class.\n\n self.assertEqual(5, len(mock_token.mock_calls))","commit_id":"3dd3608ced8b9529184d53e51bd05ba105daef81"},{"author":{"_account_id":841,"name":"Akihiro Motoki","email":"amotoki@gmail.com","username":"amotoki"},"change_message_id":"52a28b4a50f136031c7e937d70695623fa1471f2","unresolved":false,"context_lines":[{"line_number":637,"context_line":"        # POST to the page to log in."},{"line_number":638,"context_line":"        response \u003d self.client.post(url, form_data)"},{"line_number":639,"context_line":"        self.assertRedirects(response, settings.LOGIN_REDIRECT_URL)"},{"line_number":640,"context_line":""},{"line_number":641,"context_line":"        mock_token.assert_has_calls(["},{"line_number":642,"context_line":"            mock.call("},{"line_number":643,"context_line":"                auth_url\u003dsettings.OPENSTACK_KEYSTONE_URL,"}],"source_content_type":"text/x-python","patch_set":2,"id":"1fa4df85_bce9d5b7","line":640,"in_reply_to":"1fa4df85_93596c8f","updated":"2020-03-03 06:45:09.000000000","message":"Done","commit_id":"3dd3608ced8b9529184d53e51bd05ba105daef81"},{"author":{"_account_id":841,"name":"Akihiro Motoki","email":"amotoki@gmail.com","username":"amotoki"},"change_message_id":"a0a3669fcf358b705888842bd02c41948a6de6a8","unresolved":false,"context_lines":[{"line_number":646,"context_line":"                reauthenticate\u003dFalse,"},{"line_number":647,"context_line":"            ),"},{"line_number":648,"context_line":"            mock.call().__bool__(),"},{"line_number":649,"context_line":"            mock.call().get_access(mock.ANY),"},{"line_number":650,"context_line":"            mock.call("},{"line_number":651,"context_line":"                auth_url\u003dsettings.OPENSTACK_KEYSTONE_URL,"},{"line_number":652,"context_line":"                token\u003dself.data.unscoped_access_info.auth_token,"}],"source_content_type":"text/x-python","patch_set":2,"id":"1fa4df85_13f1fc95","line":649,"range":{"start_line":649,"start_character":35,"end_line":649,"end_character":43},"updated":"2020-03-03 00:23:13.000000000","message":"Could you use \"IsA(session.Session)\" instead of mock.ANY?\nWe introduced IsA (found at L.40 above) to check if an argument is an instance of an expected class.","commit_id":"3dd3608ced8b9529184d53e51bd05ba105daef81"},{"author":{"_account_id":841,"name":"Akihiro Motoki","email":"amotoki@gmail.com","username":"amotoki"},"change_message_id":"52a28b4a50f136031c7e937d70695623fa1471f2","unresolved":false,"context_lines":[{"line_number":646,"context_line":"                reauthenticate\u003dFalse,"},{"line_number":647,"context_line":"            ),"},{"line_number":648,"context_line":"            mock.call().__bool__(),"},{"line_number":649,"context_line":"            mock.call().get_access(mock.ANY),"},{"line_number":650,"context_line":"            mock.call("},{"line_number":651,"context_line":"                auth_url\u003dsettings.OPENSTACK_KEYSTONE_URL,"},{"line_number":652,"context_line":"                token\u003dself.data.unscoped_access_info.auth_token,"}],"source_content_type":"text/x-python","patch_set":2,"id":"1fa4df85_5cd22102","line":649,"range":{"start_line":649,"start_character":35,"end_line":649,"end_character":43},"in_reply_to":"1fa4df85_13f1fc95","updated":"2020-03-03 06:45:09.000000000","message":"Done\n\nI noticed you use IsA() in the later changes :)","commit_id":"3dd3608ced8b9529184d53e51bd05ba105daef81"},{"author":{"_account_id":841,"name":"Akihiro Motoki","email":"amotoki@gmail.com","username":"amotoki"},"change_message_id":"adbef6a3224ddfcd148a6824e079b5198badd559","unresolved":false,"context_lines":[{"line_number":653,"context_line":"                project_id\u003dself.data.project_one.id,"},{"line_number":654,"context_line":"                reauthenticate\u003dFalse,"},{"line_number":655,"context_line":"            ),"},{"line_number":656,"context_line":"            mock.call().get_access(mock.ANY),"},{"line_number":657,"context_line":"        ])"},{"line_number":658,"context_line":""},{"line_number":659,"context_line":"        mock_client.assert_has_calls(["}],"source_content_type":"text/x-python","patch_set":2,"id":"1fa4df85_5c146144","line":656,"updated":"2020-03-03 06:11:41.000000000","message":"The first get_access() at L.649 is called against the returned object by L.642 and the second get_access here is called against the object from L.650. Isn\u0027t it better to distinguish these two?\n\nComparing the previous and proposed ones, variable names like \"unscoped_auth\" or \"\"","commit_id":"3dd3608ced8b9529184d53e51bd05ba105daef81"}]}
