-
Notifications
You must be signed in to change notification settings - Fork 65
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[6.15.z] Navigation search: input clear fix #1234
[6.15.z] Navigation search: input clear fix #1234
Conversation
More sophisticated approach for clearing the search input. Sometimes the previous value still remained in the search input, even when clear() was called several times in a row. This was probably a timing issue when running on a rel. fast browser machine. (cherry picked from commit 37bf497)
trigger: test-robottelo |
airgun/widgets.py
Outdated
@@ -856,7 +856,7 @@ class PF4NavSearch(PF4Search): | |||
search_button = Button(locator=(".//button[@aria-label='Search']")) | |||
clear_button = Button(locator=(".//button[@aria-label='Reset']")) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
clear_button = Button(locator=(".//button[@aria-label='Reset']")) | |
clear_button = PF4Button(locator=(".//button[@aria-label='Reset']")) |
Change the class of the button to the PF4Button.
It needs to be imported:
from widgetastic_patternfly4 import Button as PF4Button
and if imported like this, you need to also change the import on line 30 from:
from widgetastic_patternfly4.ouia import BaseSelect, Button as PF4Button, Dropdown, Menu
to
from widgetastic_patternfly4.ouia import BaseSelect, Button as OUIAButton, Dropdown, Menu
and then change the former occurrences of PF4Button
to OUIAButton
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@LadislavVasina1 nice find, @pnovotny can you please also update the same in the master as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@omkarkhatavkar sure. I will create new PR for master because the #1233 was alerady merged.
Vertical menu search buttons should use the correct PF4 button widgets. This fixes the search clearing issue, when a search text value pops back after clearing the search input via browser.clear() The original PF4Button import alias was renamed to OUIAButton.
PRT passed on SatelliteQE/robottelo#14077, Could you fix the pre-commit? |
The pre-commit is now finally passing. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK, good to merge imo
Cherrypick of PR: #1233
More sophisticated approach for clearing the search input.
Sometimes the previous value still remained in the search input,
even when
clear()
was called several times in a row.This was probably a timing issue when running on a rel. fast browser machine.