)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"6080e32fe40c1386c2c5abf0ea5ab34a42a60d0a","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"dd2a10d0_42e29150","updated":"2024-07-25 16:44:30.000000000","message":"1 question on test removal, keypair filter fix lgtm","commit_id":"b2906e8308ad6b323dd070d513a6bde675b0b0d1"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"0c1c66473d3c85c296981f8129a2425e9456af66","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"2308cc17_896bbb54","updated":"2024-07-30 17:32:26.000000000","message":"Thanks Katarina, I suggested some change so that existing tests can be run as it is or with some modification. We should not delete the test unless we delete the related functionality if functionality logic is changed then test can be changed but not delete.","commit_id":"b2906e8308ad6b323dd070d513a6bde675b0b0d1"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"0237989f6e76be1ef35e75a4b75240e2c6329e3c","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"dfbf76ef_4539dcb9","updated":"2024-07-25 11:08:02.000000000","message":"lgtm, this fixes a bug mentioned in this comment (it doesn\u0027t have its own LP):\nhttps://bugs.launchpad.net/tempest/+bug/2066214/comments/3","commit_id":"b2906e8308ad6b323dd070d513a6bde675b0b0d1"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"078eefa14105ac3935a4618faf6f7c6c3ce9defe","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"fb7d08c2_bd593552","updated":"2024-07-25 13:11:43.000000000","message":"recheck ironic-tempest-bios-ipmi-direct-tinyipa failing","commit_id":"b2906e8308ad6b323dd070d513a6bde675b0b0d1"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"9a80faea8bd7401663af7f34d885713eaa081994","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"4e085f64_aceb726d","in_reply_to":"dfbf76ef_4539dcb9","updated":"2024-07-25 16:45:21.000000000","message":"++, thanks for detecting it. nice catch.","commit_id":"b2906e8308ad6b323dd070d513a6bde675b0b0d1"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"27c5f1a37733b5c0c3ddb8f4e2803c1d2a6ed018","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"62a97480_c2fbfc23","updated":"2024-07-31 19:33:48.000000000","message":"thanks, lgtm","commit_id":"0795166adf635621fce356387f1b7e3916fdce51"}],"tempest/cmd/cleanup_service.py":[{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"0c1c66473d3c85c296981f8129a2425e9456af66","unresolved":true,"context_lines":[{"line_number":294,"context_line":"        keypairs \u003d client.list_keypairs()[\u0027keypairs\u0027]"},{"line_number":295,"context_line":""},{"line_number":296,"context_line":"        if self.prefix:"},{"line_number":297,"context_line":"            keypairs \u003d self._filter_by_prefix(keypairs)"},{"line_number":298,"context_line":"        elif self.is_resource_list:"},{"line_number":299,"context_line":"            keypairs \u003d [keypair for keypair in keypairs"},{"line_number":300,"context_line":"                        if keypair[\u0027keypair\u0027][\u0027name\u0027]"}],"source_content_type":"text/x-python","patch_set":1,"id":"3706775a_0fb2aa69","side":"PARENT","line":297,"range":{"start_line":297,"start_character":23,"end_line":297,"end_character":55},"updated":"2024-07-30 17:32:26.000000000","message":"with the modified method (comment above) here we can call self._filter_by_prefix(keypairs, \u0027keypair\u0027)","commit_id":"1af21705c53bc9911ea467eaeee2bc12489a43ed"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"2b4657a94525acb3de0f15cb0d488db0d7f3eb6c","unresolved":false,"context_lines":[{"line_number":294,"context_line":"        keypairs \u003d client.list_keypairs()[\u0027keypairs\u0027]"},{"line_number":295,"context_line":""},{"line_number":296,"context_line":"        if self.prefix:"},{"line_number":297,"context_line":"            keypairs \u003d self._filter_by_prefix(keypairs)"},{"line_number":298,"context_line":"        elif self.is_resource_list:"},{"line_number":299,"context_line":"            keypairs \u003d [keypair for keypair in keypairs"},{"line_number":300,"context_line":"                        if keypair[\u0027keypair\u0027][\u0027name\u0027]"}],"source_content_type":"text/x-python","patch_set":1,"id":"b2f5b79e_9709850d","side":"PARENT","line":297,"range":{"start_line":297,"start_character":23,"end_line":297,"end_character":55},"in_reply_to":"3706775a_0fb2aa69","updated":"2024-07-31 08:59:11.000000000","message":"Yes, I brought this code back and also changed up other cleanup options, so functions are called and not if statements.","commit_id":"1af21705c53bc9911ea467eaeee2bc12489a43ed"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"0c1c66473d3c85c296981f8129a2425e9456af66","unresolved":true,"context_lines":[{"line_number":115,"context_line":"        return [item for item in item_list"},{"line_number":116,"context_line":"                if item[\u0027tenant_id\u0027] \u003d\u003d self.tenant_id]"},{"line_number":117,"context_line":""},{"line_number":118,"context_line":"    def _filter_by_prefix(self, item_list):"},{"line_number":119,"context_line":"        items \u003d [item for item in item_list"},{"line_number":120,"context_line":"                 if item[\u0027name\u0027].startswith(self.prefix)]"},{"line_number":121,"context_line":"        return items"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def _filter_by_resource_list(self, item_list, attr):"}],"source_content_type":"text/x-python","patch_set":1,"id":"25f6cd56_ef17bbc1","line":120,"range":{"start_line":118,"start_character":0,"end_line":120,"end_character":57},"updated":"2024-07-30 17:32:26.000000000","message":"to handle the kaypair extra top key we can modify this method itself (so that it can be used for other resources having extra top key in response body).\n\n    def _filter_by_prefix(self, item_list, top_key\u003dNone):\n        items \u003d []\n        for item in item_list\n            name \u003d item[top_key][\u0027name\u0027] if top_key else item[\u0027name\u0027]\n            if name.startswith(self.prefix)]:\n                items.append(item)","commit_id":"b2906e8308ad6b323dd070d513a6bde675b0b0d1"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"2b4657a94525acb3de0f15cb0d488db0d7f3eb6c","unresolved":false,"context_lines":[{"line_number":115,"context_line":"        return [item for item in item_list"},{"line_number":116,"context_line":"                if item[\u0027tenant_id\u0027] \u003d\u003d self.tenant_id]"},{"line_number":117,"context_line":""},{"line_number":118,"context_line":"    def _filter_by_prefix(self, item_list):"},{"line_number":119,"context_line":"        items \u003d [item for item in item_list"},{"line_number":120,"context_line":"                 if item[\u0027name\u0027].startswith(self.prefix)]"},{"line_number":121,"context_line":"        return items"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def _filter_by_resource_list(self, item_list, attr):"}],"source_content_type":"text/x-python","patch_set":1,"id":"2d9bc6a5_4be9f7f9","line":120,"range":{"start_line":118,"start_character":0,"end_line":120,"end_character":57},"in_reply_to":"25f6cd56_ef17bbc1","updated":"2024-07-31 08:59:11.000000000","message":"Ack, I have changed the method to be able to work with keypairs as you suggested. I have also modified other methods, so cleanup of all resources uses these methods and not if statements.","commit_id":"b2906e8308ad6b323dd070d513a6bde675b0b0d1"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"0c1c66473d3c85c296981f8129a2425e9456af66","unresolved":true,"context_lines":[{"line_number":294,"context_line":"        keypairs \u003d client.list_keypairs()[\u0027keypairs\u0027]"},{"line_number":295,"context_line":""},{"line_number":296,"context_line":"        if self.prefix:"},{"line_number":297,"context_line":"            keypairs \u003d [keypair for keypair in keypairs"},{"line_number":298,"context_line":"                        if keypair[\u0027keypair\u0027][\u0027name\u0027].startswith(self.prefix)]"},{"line_number":299,"context_line":"        elif self.is_resource_list:"},{"line_number":300,"context_line":"            keypairs \u003d [keypair for keypair in keypairs"},{"line_number":301,"context_line":"                        if keypair[\u0027keypair\u0027][\u0027name\u0027]"}],"source_content_type":"text/x-python","patch_set":1,"id":"25fd4398_9a18806d","line":298,"range":{"start_line":297,"start_character":0,"end_line":298,"end_character":78},"updated":"2024-07-30 17:32:26.000000000","message":"if test is become complicated with this change (cannot check mock _filter_by_prefix) then we can modified this logic in _filter_by_prefix() method itself. I am commenting above on how to do that and then test should be deleted(can be modified if needed)","commit_id":"b2906e8308ad6b323dd070d513a6bde675b0b0d1"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"27c5f1a37733b5c0c3ddb8f4e2803c1d2a6ed018","unresolved":false,"context_lines":[{"line_number":294,"context_line":"        keypairs \u003d client.list_keypairs()[\u0027keypairs\u0027]"},{"line_number":295,"context_line":""},{"line_number":296,"context_line":"        if self.prefix:"},{"line_number":297,"context_line":"            keypairs \u003d [keypair for keypair in keypairs"},{"line_number":298,"context_line":"                        if keypair[\u0027keypair\u0027][\u0027name\u0027].startswith(self.prefix)]"},{"line_number":299,"context_line":"        elif self.is_resource_list:"},{"line_number":300,"context_line":"            keypairs \u003d [keypair for keypair in keypairs"},{"line_number":301,"context_line":"                        if keypair[\u0027keypair\u0027][\u0027name\u0027]"}],"source_content_type":"text/x-python","patch_set":1,"id":"ad574be0_03c9cab0","line":298,"range":{"start_line":297,"start_character":0,"end_line":298,"end_character":78},"in_reply_to":"25fd4398_9a18806d","updated":"2024-07-31 19:33:48.000000000","message":"Done","commit_id":"b2906e8308ad6b323dd070d513a6bde675b0b0d1"}],"tempest/tests/cmd/test_cleanup_services.py":[{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"68dbc0af774ba880fae0e5a9681dd1132bd39037","unresolved":true,"context_lines":[{"line_number":599,"context_line":"            (self.validate_response, \u0027validate\u0027, None)"},{"line_number":600,"context_line":"        ])"},{"line_number":601,"context_line":""},{"line_number":602,"context_line":"    def test_prefix_opt_precedence(self):"},{"line_number":603,"context_line":"        delete_mock \u003d [(self.filter_saved_state, [], None),"},{"line_number":604,"context_line":"                       (self.filter_resource_list, [], None),"},{"line_number":605,"context_line":"                       (self.filter_prefix, [], None),"},{"line_number":606,"context_line":"                       (self.get_method, self.response, 200),"},{"line_number":607,"context_line":"                       (self.validate_response, \u0027validate\u0027, None),"},{"line_number":608,"context_line":"                       (self.delete_method, \u0027error\u0027, None),"},{"line_number":609,"context_line":"                       (self.log_method, \u0027exception\u0027, None)]"},{"line_number":610,"context_line":"        self._test_prefix_opt_precedence(delete_mock)"},{"line_number":611,"context_line":""},{"line_number":612,"context_line":"    def test_resource_list_opt_precedence(self):"},{"line_number":613,"context_line":"        delete_mock \u003d [(self.filter_prefix, [], None),"}],"source_content_type":"text/x-python","patch_set":1,"id":"5cb837c6_5268fdb9","side":"PARENT","line":610,"range":{"start_line":602,"start_character":1,"end_line":610,"end_character":53},"updated":"2024-07-25 22:17:38.000000000","message":"as i see it, this one is deleted because it was verifying that the code calls \"_filter_by_prefix\" method:\nhttps://opendev.org/openstack/tempest/src/commit/1af21705c53bc9911ea467eaeee2bc12489a43ed/tempest/tests/cmd/test_cleanup_services.py#L296\n\nHowever, after the changes, the code doesn\u0027t use that method anymore - so it\u0027s not called - the test is useless","commit_id":"1af21705c53bc9911ea467eaeee2bc12489a43ed"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"73e4df55ce5b60457b127f9f995c98f76ea33fd3","unresolved":true,"context_lines":[{"line_number":599,"context_line":"            (self.validate_response, \u0027validate\u0027, None)"},{"line_number":600,"context_line":"        ])"},{"line_number":601,"context_line":""},{"line_number":602,"context_line":"    def test_prefix_opt_precedence(self):"},{"line_number":603,"context_line":"        delete_mock \u003d [(self.filter_saved_state, [], None),"},{"line_number":604,"context_line":"                       (self.filter_resource_list, [], None),"},{"line_number":605,"context_line":"                       (self.filter_prefix, [], None),"},{"line_number":606,"context_line":"                       (self.get_method, self.response, 200),"},{"line_number":607,"context_line":"                       (self.validate_response, \u0027validate\u0027, None),"},{"line_number":608,"context_line":"                       (self.delete_method, \u0027error\u0027, None),"},{"line_number":609,"context_line":"                       (self.log_method, \u0027exception\u0027, None)]"},{"line_number":610,"context_line":"        self._test_prefix_opt_precedence(delete_mock)"},{"line_number":611,"context_line":""},{"line_number":612,"context_line":"    def test_resource_list_opt_precedence(self):"},{"line_number":613,"context_line":"        delete_mock \u003d [(self.filter_prefix, [], None),"}],"source_content_type":"text/x-python","patch_set":1,"id":"e780fcb9_e222bafd","side":"PARENT","line":610,"range":{"start_line":602,"start_character":1,"end_line":610,"end_character":53},"in_reply_to":"5cb837c6_5268fdb9","updated":"2024-07-30 09:08:58.000000000","message":"Yes, after the change this test does not test anything.","commit_id":"1af21705c53bc9911ea467eaeee2bc12489a43ed"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"0c1c66473d3c85c296981f8129a2425e9456af66","unresolved":true,"context_lines":[{"line_number":599,"context_line":"            (self.validate_response, \u0027validate\u0027, None)"},{"line_number":600,"context_line":"        ])"},{"line_number":601,"context_line":""},{"line_number":602,"context_line":"    def test_prefix_opt_precedence(self):"},{"line_number":603,"context_line":"        delete_mock \u003d [(self.filter_saved_state, [], None),"},{"line_number":604,"context_line":"                       (self.filter_resource_list, [], None),"},{"line_number":605,"context_line":"                       (self.filter_prefix, [], None),"},{"line_number":606,"context_line":"                       (self.get_method, self.response, 200),"},{"line_number":607,"context_line":"                       (self.validate_response, \u0027validate\u0027, None),"},{"line_number":608,"context_line":"                       (self.delete_method, \u0027error\u0027, None),"},{"line_number":609,"context_line":"                       (self.log_method, \u0027exception\u0027, None)]"},{"line_number":610,"context_line":"        self._test_prefix_opt_precedence(delete_mock)"},{"line_number":611,"context_line":""},{"line_number":612,"context_line":"    def test_resource_list_opt_precedence(self):"},{"line_number":613,"context_line":"        delete_mock \u003d [(self.filter_prefix, [], None),"}],"source_content_type":"text/x-python","patch_set":1,"id":"f772a6ad_a4a45fc8","side":"PARENT","line":610,"range":{"start_line":602,"start_character":1,"end_line":610,"end_character":53},"in_reply_to":"e780fcb9_e222bafd","updated":"2024-07-30 17:32:26.000000000","message":"This is still valid test as we are not removing \u0027keypair cleanup using prefix\u0027. If we are removing \u0027keypair cannot be removed via prefix\u0027 then we should remove these tests otherwise deleting these test decrease the test coverage.\n\nThis change changes the way to list the keypairs via prefix so tests can be modified accordingly but cannot be removed.","commit_id":"1af21705c53bc9911ea467eaeee2bc12489a43ed"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"2b4657a94525acb3de0f15cb0d488db0d7f3eb6c","unresolved":false,"context_lines":[{"line_number":599,"context_line":"            (self.validate_response, \u0027validate\u0027, None)"},{"line_number":600,"context_line":"        ])"},{"line_number":601,"context_line":""},{"line_number":602,"context_line":"    def test_prefix_opt_precedence(self):"},{"line_number":603,"context_line":"        delete_mock \u003d [(self.filter_saved_state, [], None),"},{"line_number":604,"context_line":"                       (self.filter_resource_list, [], None),"},{"line_number":605,"context_line":"                       (self.filter_prefix, [], None),"},{"line_number":606,"context_line":"                       (self.get_method, self.response, 200),"},{"line_number":607,"context_line":"                       (self.validate_response, \u0027validate\u0027, None),"},{"line_number":608,"context_line":"                       (self.delete_method, \u0027error\u0027, None),"},{"line_number":609,"context_line":"                       (self.log_method, \u0027exception\u0027, None)]"},{"line_number":610,"context_line":"        self._test_prefix_opt_precedence(delete_mock)"},{"line_number":611,"context_line":""},{"line_number":612,"context_line":"    def test_resource_list_opt_precedence(self):"},{"line_number":613,"context_line":"        delete_mock \u003d [(self.filter_prefix, [], None),"}],"source_content_type":"text/x-python","patch_set":1,"id":"0cb2fe83_6e2dc457","side":"PARENT","line":610,"range":{"start_line":602,"start_character":1,"end_line":610,"end_character":53},"in_reply_to":"f772a6ad_a4a45fc8","updated":"2024-07-31 08:59:11.000000000","message":"Acknowledged. The tests are now modified and not deleted.","commit_id":"1af21705c53bc9911ea467eaeee2bc12489a43ed"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"68dbc0af774ba880fae0e5a9681dd1132bd39037","unresolved":true,"context_lines":[{"line_number":609,"context_line":"                       (self.log_method, \u0027exception\u0027, None)]"},{"line_number":610,"context_line":"        self._test_prefix_opt_precedence(delete_mock)"},{"line_number":611,"context_line":""},{"line_number":612,"context_line":"    def test_resource_list_opt_precedence(self):"},{"line_number":613,"context_line":"        delete_mock \u003d [(self.filter_prefix, [], None),"},{"line_number":614,"context_line":"                       (self.get_method, self.response, 200),"},{"line_number":615,"context_line":"                       (self.validate_response, \u0027validate\u0027, None),"}],"source_content_type":"text/x-python","patch_set":1,"id":"c43cf7fb_2fab8da8","side":"PARENT","line":612,"range":{"start_line":612,"start_character":8,"end_line":612,"end_character":41},"updated":"2024-07-25 22:17:38.000000000","message":"on a second look, this test seems to work though, so maybe we could keep this one?","commit_id":"1af21705c53bc9911ea467eaeee2bc12489a43ed"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"73e4df55ce5b60457b127f9f995c98f76ea33fd3","unresolved":true,"context_lines":[{"line_number":609,"context_line":"                       (self.log_method, \u0027exception\u0027, None)]"},{"line_number":610,"context_line":"        self._test_prefix_opt_precedence(delete_mock)"},{"line_number":611,"context_line":""},{"line_number":612,"context_line":"    def test_resource_list_opt_precedence(self):"},{"line_number":613,"context_line":"        delete_mock \u003d [(self.filter_prefix, [], None),"},{"line_number":614,"context_line":"                       (self.get_method, self.response, 200),"},{"line_number":615,"context_line":"                       (self.validate_response, \u0027validate\u0027, None),"}],"source_content_type":"text/x-python","patch_set":1,"id":"f6a15363_e7498378","side":"PARENT","line":612,"range":{"start_line":612,"start_character":8,"end_line":612,"end_character":41},"in_reply_to":"c43cf7fb_2fab8da8","updated":"2024-07-30 09:08:58.000000000","message":"This test will also not work, because fixtures[0] are non-existent when we change it from function to if statement. If I understand it correctly.","commit_id":"1af21705c53bc9911ea467eaeee2bc12489a43ed"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"27c5f1a37733b5c0c3ddb8f4e2803c1d2a6ed018","unresolved":false,"context_lines":[{"line_number":609,"context_line":"                       (self.log_method, \u0027exception\u0027, None)]"},{"line_number":610,"context_line":"        self._test_prefix_opt_precedence(delete_mock)"},{"line_number":611,"context_line":""},{"line_number":612,"context_line":"    def test_resource_list_opt_precedence(self):"},{"line_number":613,"context_line":"        delete_mock \u003d [(self.filter_prefix, [], None),"},{"line_number":614,"context_line":"                       (self.get_method, self.response, 200),"},{"line_number":615,"context_line":"                       (self.validate_response, \u0027validate\u0027, None),"}],"source_content_type":"text/x-python","patch_set":1,"id":"4ba16ad3_51940ad4","side":"PARENT","line":612,"range":{"start_line":612,"start_character":8,"end_line":612,"end_character":41},"in_reply_to":"f6a15363_e7498378","updated":"2024-07-31 19:33:48.000000000","message":"Done","commit_id":"1af21705c53bc9911ea467eaeee2bc12489a43ed"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"6080e32fe40c1386c2c5abf0ea5ab34a42a60d0a","unresolved":true,"context_lines":[{"line_number":599,"context_line":"            (self.validate_response, \u0027validate\u0027, None)"},{"line_number":600,"context_line":"        ])"},{"line_number":601,"context_line":""},{"line_number":602,"context_line":"    def test_prefix_opt_precedence(self):"},{"line_number":603,"context_line":"        delete_mock \u003d [(self.filter_saved_state, [], None),"},{"line_number":604,"context_line":"                       (self.filter_resource_list, [], None),"},{"line_number":605,"context_line":"                       (self.filter_prefix, [], None),"},{"line_number":606,"context_line":"                       (self.get_method, self.response, 200),"},{"line_number":607,"context_line":"                       (self.validate_response, \u0027validate\u0027, None),"},{"line_number":608,"context_line":"                       (self.delete_method, \u0027error\u0027, None),"},{"line_number":609,"context_line":"                       (self.log_method, \u0027exception\u0027, None)]"},{"line_number":610,"context_line":"        self._test_prefix_opt_precedence(delete_mock)"},{"line_number":611,"context_line":""},{"line_number":612,"context_line":"    def test_resource_list_opt_precedence(self):"},{"line_number":613,"context_line":"        delete_mock \u003d [(self.filter_prefix, [], None),"},{"line_number":614,"context_line":"                       (self.get_method, self.response, 200),"},{"line_number":615,"context_line":"                       (self.validate_response, \u0027validate\u0027, None),"},{"line_number":616,"context_line":"                       (self.delete_method, \u0027error\u0027, None),"},{"line_number":617,"context_line":"                       (self.log_method, \u0027exception\u0027, None)]"},{"line_number":618,"context_line":"        serv \u003d self._create_cmd_service("},{"line_number":619,"context_line":"            self.service_class, is_resource_list\u003dTrue)"},{"line_number":620,"context_line":""},{"line_number":621,"context_line":"        _, fixtures \u003d self.run_function_with_mocks("},{"line_number":622,"context_line":"            serv.delete,"},{"line_number":623,"context_line":"            delete_mock"},{"line_number":624,"context_line":"        )"},{"line_number":625,"context_line":""},{"line_number":626,"context_line":"        # Check that prefix was not used for filtering"},{"line_number":627,"context_line":"        fixtures[0].mock.assert_not_called()"},{"line_number":628,"context_line":""},{"line_number":629,"context_line":""},{"line_number":630,"context_line":"class TestVolumeService(BaseCmdServiceTests):"}],"source_content_type":"text/x-python","patch_set":1,"id":"2c794507_42af945b","side":"PARENT","line":627,"range":{"start_line":602,"start_character":0,"end_line":627,"end_character":44},"updated":"2024-07-25 16:44:30.000000000","message":"I could not get the reason of deleting the test. can you please explain it","commit_id":"1af21705c53bc9911ea467eaeee2bc12489a43ed"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"73e4df55ce5b60457b127f9f995c98f76ea33fd3","unresolved":true,"context_lines":[{"line_number":599,"context_line":"            (self.validate_response, \u0027validate\u0027, None)"},{"line_number":600,"context_line":"        ])"},{"line_number":601,"context_line":""},{"line_number":602,"context_line":"    def test_prefix_opt_precedence(self):"},{"line_number":603,"context_line":"        delete_mock \u003d [(self.filter_saved_state, [], None),"},{"line_number":604,"context_line":"                       (self.filter_resource_list, [], None),"},{"line_number":605,"context_line":"                       (self.filter_prefix, [], None),"},{"line_number":606,"context_line":"                       (self.get_method, self.response, 200),"},{"line_number":607,"context_line":"                       (self.validate_response, \u0027validate\u0027, None),"},{"line_number":608,"context_line":"                       (self.delete_method, \u0027error\u0027, None),"},{"line_number":609,"context_line":"                       (self.log_method, \u0027exception\u0027, None)]"},{"line_number":610,"context_line":"        self._test_prefix_opt_precedence(delete_mock)"},{"line_number":611,"context_line":""},{"line_number":612,"context_line":"    def test_resource_list_opt_precedence(self):"},{"line_number":613,"context_line":"        delete_mock \u003d [(self.filter_prefix, [], None),"},{"line_number":614,"context_line":"                       (self.get_method, self.response, 200),"},{"line_number":615,"context_line":"                       (self.validate_response, \u0027validate\u0027, None),"},{"line_number":616,"context_line":"                       (self.delete_method, \u0027error\u0027, None),"},{"line_number":617,"context_line":"                       (self.log_method, \u0027exception\u0027, None)]"},{"line_number":618,"context_line":"        serv \u003d self._create_cmd_service("},{"line_number":619,"context_line":"            self.service_class, is_resource_list\u003dTrue)"},{"line_number":620,"context_line":""},{"line_number":621,"context_line":"        _, fixtures \u003d self.run_function_with_mocks("},{"line_number":622,"context_line":"            serv.delete,"},{"line_number":623,"context_line":"            delete_mock"},{"line_number":624,"context_line":"        )"},{"line_number":625,"context_line":""},{"line_number":626,"context_line":"        # Check that prefix was not used for filtering"},{"line_number":627,"context_line":"        fixtures[0].mock.assert_not_called()"},{"line_number":628,"context_line":""},{"line_number":629,"context_line":""},{"line_number":630,"context_line":"class TestVolumeService(BaseCmdServiceTests):"}],"source_content_type":"text/x-python","patch_set":1,"id":"f3ac1b36_685c664c","side":"PARENT","line":627,"range":{"start_line":602,"start_character":0,"end_line":627,"end_character":44},"in_reply_to":"2c794507_42af945b","updated":"2024-07-30 09:08:58.000000000","message":"The logic behind these test is gone with the change. Now these tests don\u0027t test anything. I had two options how to resolve this:\n1. delete the tests as they are now useless\n2. rewrite these tests, but with more complicated logic\n\nI am not very good at writing unit tests, but I have tried to think of a way this would be accomplished and I have not found an easy way. If you are against deleting these tests, I would need help with finding a way to test the new code. Any ideas?","commit_id":"1af21705c53bc9911ea467eaeee2bc12489a43ed"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"2b4657a94525acb3de0f15cb0d488db0d7f3eb6c","unresolved":false,"context_lines":[{"line_number":599,"context_line":"            (self.validate_response, \u0027validate\u0027, None)"},{"line_number":600,"context_line":"        ])"},{"line_number":601,"context_line":""},{"line_number":602,"context_line":"    def test_prefix_opt_precedence(self):"},{"line_number":603,"context_line":"        delete_mock \u003d [(self.filter_saved_state, [], None),"},{"line_number":604,"context_line":"                       (self.filter_resource_list, [], None),"},{"line_number":605,"context_line":"                       (self.filter_prefix, [], None),"},{"line_number":606,"context_line":"                       (self.get_method, self.response, 200),"},{"line_number":607,"context_line":"                       (self.validate_response, \u0027validate\u0027, None),"},{"line_number":608,"context_line":"                       (self.delete_method, \u0027error\u0027, None),"},{"line_number":609,"context_line":"                       (self.log_method, \u0027exception\u0027, None)]"},{"line_number":610,"context_line":"        self._test_prefix_opt_precedence(delete_mock)"},{"line_number":611,"context_line":""},{"line_number":612,"context_line":"    def test_resource_list_opt_precedence(self):"},{"line_number":613,"context_line":"        delete_mock \u003d [(self.filter_prefix, [], None),"},{"line_number":614,"context_line":"                       (self.get_method, self.response, 200),"},{"line_number":615,"context_line":"                       (self.validate_response, \u0027validate\u0027, None),"},{"line_number":616,"context_line":"                       (self.delete_method, \u0027error\u0027, None),"},{"line_number":617,"context_line":"                       (self.log_method, \u0027exception\u0027, None)]"},{"line_number":618,"context_line":"        serv \u003d self._create_cmd_service("},{"line_number":619,"context_line":"            self.service_class, is_resource_list\u003dTrue)"},{"line_number":620,"context_line":""},{"line_number":621,"context_line":"        _, fixtures \u003d self.run_function_with_mocks("},{"line_number":622,"context_line":"            serv.delete,"},{"line_number":623,"context_line":"            delete_mock"},{"line_number":624,"context_line":"        )"},{"line_number":625,"context_line":""},{"line_number":626,"context_line":"        # Check that prefix was not used for filtering"},{"line_number":627,"context_line":"        fixtures[0].mock.assert_not_called()"},{"line_number":628,"context_line":""},{"line_number":629,"context_line":""},{"line_number":630,"context_line":"class TestVolumeService(BaseCmdServiceTests):"}],"source_content_type":"text/x-python","patch_set":1,"id":"97255a63_790fc129","side":"PARENT","line":627,"range":{"start_line":602,"start_character":0,"end_line":627,"end_character":44},"in_reply_to":"b9f1a2e7_14de17b6","updated":"2024-07-31 08:59:11.000000000","message":"Acknowledged","commit_id":"1af21705c53bc9911ea467eaeee2bc12489a43ed"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"0c1c66473d3c85c296981f8129a2425e9456af66","unresolved":true,"context_lines":[{"line_number":599,"context_line":"            (self.validate_response, \u0027validate\u0027, None)"},{"line_number":600,"context_line":"        ])"},{"line_number":601,"context_line":""},{"line_number":602,"context_line":"    def test_prefix_opt_precedence(self):"},{"line_number":603,"context_line":"        delete_mock \u003d [(self.filter_saved_state, [], None),"},{"line_number":604,"context_line":"                       (self.filter_resource_list, [], None),"},{"line_number":605,"context_line":"                       (self.filter_prefix, [], None),"},{"line_number":606,"context_line":"                       (self.get_method, self.response, 200),"},{"line_number":607,"context_line":"                       (self.validate_response, \u0027validate\u0027, None),"},{"line_number":608,"context_line":"                       (self.delete_method, \u0027error\u0027, None),"},{"line_number":609,"context_line":"                       (self.log_method, \u0027exception\u0027, None)]"},{"line_number":610,"context_line":"        self._test_prefix_opt_precedence(delete_mock)"},{"line_number":611,"context_line":""},{"line_number":612,"context_line":"    def test_resource_list_opt_precedence(self):"},{"line_number":613,"context_line":"        delete_mock \u003d [(self.filter_prefix, [], None),"},{"line_number":614,"context_line":"                       (self.get_method, self.response, 200),"},{"line_number":615,"context_line":"                       (self.validate_response, \u0027validate\u0027, None),"},{"line_number":616,"context_line":"                       (self.delete_method, \u0027error\u0027, None),"},{"line_number":617,"context_line":"                       (self.log_method, \u0027exception\u0027, None)]"},{"line_number":618,"context_line":"        serv \u003d self._create_cmd_service("},{"line_number":619,"context_line":"            self.service_class, is_resource_list\u003dTrue)"},{"line_number":620,"context_line":""},{"line_number":621,"context_line":"        _, fixtures \u003d self.run_function_with_mocks("},{"line_number":622,"context_line":"            serv.delete,"},{"line_number":623,"context_line":"            delete_mock"},{"line_number":624,"context_line":"        )"},{"line_number":625,"context_line":""},{"line_number":626,"context_line":"        # Check that prefix was not used for filtering"},{"line_number":627,"context_line":"        fixtures[0].mock.assert_not_called()"},{"line_number":628,"context_line":""},{"line_number":629,"context_line":""},{"line_number":630,"context_line":"class TestVolumeService(BaseCmdServiceTests):"}],"source_content_type":"text/x-python","patch_set":1,"id":"b9f1a2e7_14de17b6","side":"PARENT","line":627,"range":{"start_line":602,"start_character":0,"end_line":627,"end_character":44},"in_reply_to":"f3ac1b36_685c664c","updated":"2024-07-30 17:32:26.000000000","message":"the logic we changed in this is \u0027how to filter list with prefix\u0027 from \u0027keypair[\u0027name\u0027].startswith(self.prefix)]\u0027 to \u0027keypair[\u0027keypair\u0027][\u0027name\u0027].startswith(self.prefix)]\u0027 so there is no change in prefix filter functionality so both test should exist but modify them to filter  with \u0027keypair[\u0027keypair\u0027][\u0027name\u0027].startswith(self.prefix)]\u0027","commit_id":"1af21705c53bc9911ea467eaeee2bc12489a43ed"}]}
