)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":29313,"name":"Vishal Manchanda","email":"manchandavishal143@gmail.com","username":"vishalmanchanda"},"change_message_id":"3d7d2dc8797017740e463dbfcb6576f37a960fe5","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"acff72f5_a36f8062","updated":"2023-09-15 05:06:53.000000000","message":"LGTM, when you are planning to make all these tests running in CI jobs?","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"},{"author":{"_account_id":35133,"name":"Jan Jasek","email":"jjasek@redhat.com","username":"janjasek"},"change_message_id":"bd475201fd1c156c6fbb7074dea75ad10469f5dc","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"0d49b78e_2fa0e990","updated":"2023-09-14 16:20:06.000000000","message":"recheck, random failure","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"},{"author":{"_account_id":35133,"name":"Jan Jasek","email":"jjasek@redhat.com","username":"janjasek"},"change_message_id":"c99bde3449a3f2a40ae80672c20cf267e7a4d947","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"36037b9a_8245f015","updated":"2023-09-14 13:37:40.000000000","message":"recheck, random failure","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"},{"author":{"_account_id":35133,"name":"Jan Jasek","email":"jjasek@redhat.com","username":"janjasek"},"change_message_id":"470d2d502a4c08259b31aa4c7cc3f6836ffe480e","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"6329b300_e54ad463","updated":"2023-09-14 14:55:27.000000000","message":"recheck, random failure","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"},{"author":{"_account_id":35133,"name":"Jan Jasek","email":"jjasek@redhat.com","username":"janjasek"},"change_message_id":"e585cc8a8dd5f43ac1ead892515e996cc6c0a438","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"6f538c74_ca545593","updated":"2023-09-14 18:32:00.000000000","message":"recheck, random failure","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"},{"author":{"_account_id":35133,"name":"Jan Jasek","email":"jjasek@redhat.com","username":"janjasek"},"change_message_id":"094d8f7a900d478f83d98cfb625fde287be17310","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"ebb6f3db_eae40911","updated":"2023-09-14 11:54:52.000000000","message":"recheck, timeout","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"},{"author":{"_account_id":8648,"name":"Radomir Dopieralski","email":"openstack@dopieralski.pl","username":"thesheep"},"change_message_id":"46e5d0ff2e0f4df9f45f92bcb81f3b45eb8826af","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"cee7a08e_6c11acd7","updated":"2023-09-28 15:28:16.000000000","message":"recheck random failure","commit_id":"435a15c804537510691162233f2755c49ad1c434"},{"author":{"_account_id":8648,"name":"Radomir Dopieralski","email":"openstack@dopieralski.pl","username":"thesheep"},"change_message_id":"ae3c5cc515e5d1228771095e773090882dac2699","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"d28a0ff0_1daed044","updated":"2023-09-28 14:02:57.000000000","message":"recheck random timeout","commit_id":"435a15c804537510691162233f2755c49ad1c434"},{"author":{"_account_id":35133,"name":"Jan Jasek","email":"jjasek@redhat.com","username":"janjasek"},"change_message_id":"d1a18efdd754ee2300aa96653602a00d68caf410","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"9f16f4dc_c2b9b84f","updated":"2023-09-28 12:25:18.000000000","message":"recheck, random failure","commit_id":"435a15c804537510691162233f2755c49ad1c434"},{"author":{"_account_id":8648,"name":"Radomir Dopieralski","email":"openstack@dopieralski.pl","username":"thesheep"},"change_message_id":"d7b423e7eb41ff97986773a1d501ada5d3c118bd","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"5a461725_beb36229","updated":"2023-09-28 11:23:28.000000000","message":"recheck, random timeout","commit_id":"435a15c804537510691162233f2755c49ad1c434"}],"openstack_dashboard/test/selenium/integration/test_networks.py":[{"author":{"_account_id":8648,"name":"Radomir Dopieralski","email":"openstack@dopieralski.pl","username":"thesheep"},"change_message_id":"5f9adf7df4a9698d4037de8e83f6fcf9332754a9","unresolved":true,"context_lines":[{"line_number":44,"context_line":""},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"# required_state: True/False (marked/unmarked)"},{"line_number":47,"context_line":"def checkbox_manipulation(required_state, element_id, driver):"},{"line_number":48,"context_line":"    current_state \u003d driver.find_element_by_id(element_id).is_selected()"},{"line_number":49,"context_line":"    if required_state !\u003d current_state:"},{"line_number":50,"context_line":"        driver.find_element_by_css_selector("}],"source_content_type":"text/x-python","patch_set":1,"id":"736c13da_3e20ed0d","line":47,"updated":"2023-09-15 08:14:25.000000000","message":"I would name functions as verb (or verb phrases), so in this case maybe something like \"set_checkbox\" or \"toggle_checkbox\", maybe \"ensure_checkbox\"?\n\nWhat if instead of element_id and driver you just passed the element? Then you would do the find_element on the other side, and could use any method to find it?","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"},{"author":{"_account_id":35133,"name":"Jan Jasek","email":"jjasek@redhat.com","username":"janjasek"},"change_message_id":"d0bb7dc46e53d5496e2f976f01d6813d4a46a158","unresolved":false,"context_lines":[{"line_number":44,"context_line":""},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"# required_state: True/False (marked/unmarked)"},{"line_number":47,"context_line":"def checkbox_manipulation(required_state, element_id, driver):"},{"line_number":48,"context_line":"    current_state \u003d driver.find_element_by_id(element_id).is_selected()"},{"line_number":49,"context_line":"    if required_state !\u003d current_state:"},{"line_number":50,"context_line":"        driver.find_element_by_css_selector("}],"source_content_type":"text/x-python","patch_set":1,"id":"c1444c6a_31185bed","line":47,"in_reply_to":"736c13da_3e20ed0d","updated":"2023-09-15 10:15:33.000000000","message":"Done","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"},{"author":{"_account_id":8648,"name":"Radomir Dopieralski","email":"openstack@dopieralski.pl","username":"thesheep"},"change_message_id":"5f9adf7df4a9698d4037de8e83f6fcf9332754a9","unresolved":true,"context_lines":[{"line_number":70,"context_line":"    assert f\u0027Success: Created network \"{network_name}\".\u0027 in messages"},{"line_number":71,"context_line":"    widgets.find_already_visible_element_by_xpath("},{"line_number":72,"context_line":"        f\"//*[text()\u003d\u0027{network_name}\u0027]//ancestor::tr/td\""},{"line_number":73,"context_line":"        f\"[normalize-space()\u003d\u0027Active\u0027]\", driver)"},{"line_number":74,"context_line":""},{"line_number":75,"context_line":""},{"line_number":76,"context_line":"def test_create_network_with_subnet_demo(login, driver, network_name,"}],"source_content_type":"text/x-python","patch_set":1,"id":"0db14494_0a0394ae","line":73,"updated":"2023-09-15 08:14:25.000000000","message":"why do you do anything after the assert? does it have any special effect?","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"},{"author":{"_account_id":35133,"name":"Jan Jasek","email":"jjasek@redhat.com","username":"janjasek"},"change_message_id":"d0bb7dc46e53d5496e2f976f01d6813d4a46a158","unresolved":true,"context_lines":[{"line_number":70,"context_line":"    assert f\u0027Success: Created network \"{network_name}\".\u0027 in messages"},{"line_number":71,"context_line":"    widgets.find_already_visible_element_by_xpath("},{"line_number":72,"context_line":"        f\"//*[text()\u003d\u0027{network_name}\u0027]//ancestor::tr/td\""},{"line_number":73,"context_line":"        f\"[normalize-space()\u003d\u0027Active\u0027]\", driver)"},{"line_number":74,"context_line":""},{"line_number":75,"context_line":""},{"line_number":76,"context_line":"def test_create_network_with_subnet_demo(login, driver, network_name,"}],"source_content_type":"text/x-python","patch_set":1,"id":"4957bda5_dae1a2d0","line":73,"in_reply_to":"0db14494_0a0394ae","updated":"2023-09-15 10:15:33.000000000","message":"ditto","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"},{"author":{"_account_id":35133,"name":"Jan Jasek","email":"jjasek@redhat.com","username":"janjasek"},"change_message_id":"d37b8478a18707a45ddb652487afb34926cae0f7","unresolved":false,"context_lines":[{"line_number":70,"context_line":"    assert f\u0027Success: Created network \"{network_name}\".\u0027 in messages"},{"line_number":71,"context_line":"    widgets.find_already_visible_element_by_xpath("},{"line_number":72,"context_line":"        f\"//*[text()\u003d\u0027{network_name}\u0027]//ancestor::tr/td\""},{"line_number":73,"context_line":"        f\"[normalize-space()\u003d\u0027Active\u0027]\", driver)"},{"line_number":74,"context_line":""},{"line_number":75,"context_line":""},{"line_number":76,"context_line":"def test_create_network_with_subnet_demo(login, driver, network_name,"}],"source_content_type":"text/x-python","patch_set":1,"id":"6186e32d_bca5d54e","line":73,"in_reply_to":"4957bda5_dae1a2d0","updated":"2023-09-26 12:28:38.000000000","message":"Done","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"},{"author":{"_account_id":8648,"name":"Radomir Dopieralski","email":"openstack@dopieralski.pl","username":"thesheep"},"change_message_id":"5f9adf7df4a9698d4037de8e83f6fcf9332754a9","unresolved":true,"context_lines":[{"line_number":103,"context_line":"    widgets.find_already_visible_element_by_xpath("},{"line_number":104,"context_line":"        f\"//*[text()\u003d\u0027{network_name}\u0027]//ancestor::tr/td[3]\""},{"line_number":105,"context_line":"        f\"[normalize-space()\u003d\u0027{subnet_name}\""},{"line_number":106,"context_line":"        f\" {config.network.network_cidr}\u0027]\", driver)"},{"line_number":107,"context_line":""},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"def test_delete_network_demo(login, driver, network_name,"}],"source_content_type":"text/x-python","patch_set":1,"id":"f84689df_7d0c1f18","line":106,"updated":"2023-09-15 08:14:25.000000000","message":"ditto","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"},{"author":{"_account_id":8648,"name":"Radomir Dopieralski","email":"openstack@dopieralski.pl","username":"thesheep"},"change_message_id":"405d77ed6f8383f2b7b84488d28e48bb08df6281","unresolved":true,"context_lines":[{"line_number":103,"context_line":"    widgets.find_already_visible_element_by_xpath("},{"line_number":104,"context_line":"        f\"//*[text()\u003d\u0027{network_name}\u0027]//ancestor::tr/td[3]\""},{"line_number":105,"context_line":"        f\"[normalize-space()\u003d\u0027{subnet_name}\""},{"line_number":106,"context_line":"        f\" {config.network.network_cidr}\u0027]\", driver)"},{"line_number":107,"context_line":""},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"def test_delete_network_demo(login, driver, network_name,"}],"source_content_type":"text/x-python","patch_set":1,"id":"983fd0f8_b02a2df7","line":106,"in_reply_to":"2cc98b39_60eb0c36","updated":"2023-09-15 12:08:25.000000000","message":"but don\u0027t you need to add an assert?","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"},{"author":{"_account_id":8648,"name":"Radomir Dopieralski","email":"openstack@dopieralski.pl","username":"thesheep"},"change_message_id":"f76d40ecf5eed4d6111350f60f9785e57722d4c3","unresolved":true,"context_lines":[{"line_number":103,"context_line":"    widgets.find_already_visible_element_by_xpath("},{"line_number":104,"context_line":"        f\"//*[text()\u003d\u0027{network_name}\u0027]//ancestor::tr/td[3]\""},{"line_number":105,"context_line":"        f\"[normalize-space()\u003d\u0027{subnet_name}\""},{"line_number":106,"context_line":"        f\" {config.network.network_cidr}\u0027]\", driver)"},{"line_number":107,"context_line":""},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"def test_delete_network_demo(login, driver, network_name,"}],"source_content_type":"text/x-python","patch_set":1,"id":"c332bf3a_fced4811","line":106,"in_reply_to":"81cfc0f4_5f71adc2","updated":"2023-09-15 14:44:09.000000000","message":"But a test should fail by failing an assert, if it throws an exception, that\u0027s not a failing test, that\u0027s broken test? I don\u0027t have much experience with tests, but I feel like the test should describe what is expected to happen.\n\nPerhaps something like\n\nassert driver.find_element_by_xpath(...).is_displayed()\n\nwould work? If you think it\u0027s fine how it is, I won\u0027t argue anymore.","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"},{"author":{"_account_id":35133,"name":"Jan Jasek","email":"jjasek@redhat.com","username":"janjasek"},"change_message_id":"95e4e6a40e88a8c99e5485d6cd4dc8f31e380a44","unresolved":true,"context_lines":[{"line_number":103,"context_line":"    widgets.find_already_visible_element_by_xpath("},{"line_number":104,"context_line":"        f\"//*[text()\u003d\u0027{network_name}\u0027]//ancestor::tr/td[3]\""},{"line_number":105,"context_line":"        f\"[normalize-space()\u003d\u0027{subnet_name}\""},{"line_number":106,"context_line":"        f\" {config.network.network_cidr}\u0027]\", driver)"},{"line_number":107,"context_line":""},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"def test_delete_network_demo(login, driver, network_name,"}],"source_content_type":"text/x-python","patch_set":1,"id":"81cfc0f4_5f71adc2","line":106,"in_reply_to":"983fd0f8_b02a2df7","updated":"2023-09-15 12:40:11.000000000","message":"Do I need? Sorry I am not sure where exactly you mean I should use an assert. In the state it is in now. When the network is not active or there is some issue with subnet then the test Fail as a timeout in this function: find_already_visible_element_by_xpath (because there is used expected condition that waits for visibility of element located). If everything is OK then the test finishes successfully.\nDon\u0027t depends if there is an assert or not, if it fails then it ends as a Fail because of the specific selenium.common.exception and when it pass then it pass.","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"},{"author":{"_account_id":35153,"name":"Ashish Gupta","email":"ashigupt@redhat.com","username":"ashigupt","status":"Redhat"},"change_message_id":"ac7e3c3f9145279ededa8f006a1a721bd9e10905","unresolved":true,"context_lines":[{"line_number":103,"context_line":"    widgets.find_already_visible_element_by_xpath("},{"line_number":104,"context_line":"        f\"//*[text()\u003d\u0027{network_name}\u0027]//ancestor::tr/td[3]\""},{"line_number":105,"context_line":"        f\"[normalize-space()\u003d\u0027{subnet_name}\""},{"line_number":106,"context_line":"        f\" {config.network.network_cidr}\u0027]\", driver)"},{"line_number":107,"context_line":""},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"def test_delete_network_demo(login, driver, network_name,"}],"source_content_type":"text/x-python","patch_set":1,"id":"ec285f07_50dce892","line":106,"in_reply_to":"b230a4cb_efe40b1c","updated":"2023-09-15 15:01:54.000000000","message":"is_displayed() suggested by Radomir is a good option that can be considered here.","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"},{"author":{"_account_id":35153,"name":"Ashish Gupta","email":"ashigupt@redhat.com","username":"ashigupt","status":"Redhat"},"change_message_id":"5b937e4004bb3c7c940121baadcc5d726960d939","unresolved":true,"context_lines":[{"line_number":103,"context_line":"    widgets.find_already_visible_element_by_xpath("},{"line_number":104,"context_line":"        f\"//*[text()\u003d\u0027{network_name}\u0027]//ancestor::tr/td[3]\""},{"line_number":105,"context_line":"        f\"[normalize-space()\u003d\u0027{subnet_name}\""},{"line_number":106,"context_line":"        f\" {config.network.network_cidr}\u0027]\", driver)"},{"line_number":107,"context_line":""},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"def test_delete_network_demo(login, driver, network_name,"}],"source_content_type":"text/x-python","patch_set":1,"id":"b230a4cb_efe40b1c","line":106,"in_reply_to":"c332bf3a_fced4811","updated":"2023-09-15 14:58:57.000000000","message":"I feel test should fail by an assert and a proper message instead of just failing and throwing an exception . Because we work with these tests daily so it is easy for us to understand but consider any manager or other stakeholder who doesn\u0027t have much idea about tests or selenium in particular . He or she should be able to understand from reading the logs or error message why it failed be it timeout or any other issue.Thanks","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"},{"author":{"_account_id":35133,"name":"Jan Jasek","email":"jjasek@redhat.com","username":"janjasek"},"change_message_id":"50d04c3d8f85d7c552e303d4f059ac75320c6ec8","unresolved":true,"context_lines":[{"line_number":103,"context_line":"    widgets.find_already_visible_element_by_xpath("},{"line_number":104,"context_line":"        f\"//*[text()\u003d\u0027{network_name}\u0027]//ancestor::tr/td[3]\""},{"line_number":105,"context_line":"        f\"[normalize-space()\u003d\u0027{subnet_name}\""},{"line_number":106,"context_line":"        f\" {config.network.network_cidr}\u0027]\", driver)"},{"line_number":107,"context_line":""},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"def test_delete_network_demo(login, driver, network_name,"}],"source_content_type":"text/x-python","patch_set":1,"id":"fbf6e49f_49cc4565","line":106,"in_reply_to":"ec285f07_50dce892","updated":"2023-09-15 16:29:31.000000000","message":"Sorry guys. I am little confused right now.\nIf I know then is_displayed() return True/False if the element is visible for user or not. The EXISTING element. But if the element does not exist, then it means that we do not have element on which can we apply is_displayed() function then we obviously can not get a return if element is or is not visible for user. Because the element does not exist at all. And the selenium works logically - when element does not exist at all (or timeout expired for some action), then it does not make a sense to do anything else (like check is_displayed()) or continue until it reach our assert. So it Fail test immediately on selenium.exception.\nWe can use try except and then process the exception somehow. But at this moment we can start another debate what all steps (looking for elements, waits, clicks, filling textbox) should be managed this way to not scare some manager or stakeholder by some selenium.exception...\nAnd I am not super happy from creating another functions (amount of code) that will wrap something else that will wrap something else and the result will be something informationally empty like: Test Failed because on assertxxx and then we will need to deep dive through x functions to find clear general selenium exception (like \"timeout on line xx\" or \"unable to locate element: //*[text()\u003d\u0027NonExist\u0027] on line xx\".\n\nfor: driver.find_element_by_xpath(\"//*[text()\u003d\u0027NonExist\u0027]\")\nreturn: selenium.common.exceptions.NoSuchElementException: Message: Unable to locate element\nfor: driver.find_element_by_xpath(\"//*[text()\u003d\u0027NonExist\u0027]\").is_displayed()\nreturn: selenium.common.exceptions.NoSuchElementException: Message: Unable to locate element\nfor: assert(driver.find_element_by_xpath(\"//*[text()\u003d\u0027NonExist\u0027]\").is_displayed())\nreturn: selenium.common.exceptions.NoSuchElementException: Message: Unable to locate element\n\nMAYBE I MISSED SOMETHING, I AM SUPER HAPPY THAT SKILLED GUYS LIKE YOU DO A REVIEW FOR ME. IF I AM WRONG IN SOMETHING AND YOU HAVE SOME BETTER WAY I WILL BE HAPPY TO TRY IT.","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"},{"author":{"_account_id":35133,"name":"Jan Jasek","email":"jjasek@redhat.com","username":"janjasek"},"change_message_id":"d0bb7dc46e53d5496e2f976f01d6813d4a46a158","unresolved":true,"context_lines":[{"line_number":103,"context_line":"    widgets.find_already_visible_element_by_xpath("},{"line_number":104,"context_line":"        f\"//*[text()\u003d\u0027{network_name}\u0027]//ancestor::tr/td[3]\""},{"line_number":105,"context_line":"        f\"[normalize-space()\u003d\u0027{subnet_name}\""},{"line_number":106,"context_line":"        f\" {config.network.network_cidr}\u0027]\", driver)"},{"line_number":107,"context_line":""},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"def test_delete_network_demo(login, driver, network_name,"}],"source_content_type":"text/x-python","patch_set":1,"id":"2cc98b39_60eb0c36","line":106,"in_reply_to":"f84689df_7d0c1f18","updated":"2023-09-15 10:15:33.000000000","message":"I would like to keep the checking if required part was successfully created. From my point of view it is certainly not harmful (we have to wait anyway until it is loaded to be able to delete it by openstackSDK API call), and for case like this one is relevant to check if the volume actually contains required subnet.\n(When finding element fails - there is not present required subnet or the creation fails it is relevant output for us I think)\nI know that it is on edge what we want/we should test here but for me it make a sense here.","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"},{"author":{"_account_id":35133,"name":"Jan Jasek","email":"jjasek@redhat.com","username":"janjasek"},"change_message_id":"d37b8478a18707a45ddb652487afb34926cae0f7","unresolved":false,"context_lines":[{"line_number":103,"context_line":"    widgets.find_already_visible_element_by_xpath("},{"line_number":104,"context_line":"        f\"//*[text()\u003d\u0027{network_name}\u0027]//ancestor::tr/td[3]\""},{"line_number":105,"context_line":"        f\"[normalize-space()\u003d\u0027{subnet_name}\""},{"line_number":106,"context_line":"        f\" {config.network.network_cidr}\u0027]\", driver)"},{"line_number":107,"context_line":""},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"def test_delete_network_demo(login, driver, network_name,"}],"source_content_type":"text/x-python","patch_set":1,"id":"62ea0cb7_7db48109","line":106,"in_reply_to":"fbf6e49f_49cc4565","updated":"2023-09-26 12:28:38.000000000","message":"Done","commit_id":"46fd08e9bf652ba7c7f9b6d2a50a092bd20c58c6"}]}
