Fix tests - #173
Merged
Merged
Conversation
LightOfHeaven1994
marked this pull request as draft
March 31, 2023 14:51
LightOfHeaven1994
force-pushed
the
fix-tests
branch
from
April 3, 2023 12:15
5987af6 to
a38d23b
Compare
LightOfHeaven1994
force-pushed
the
fix-tests
branch
from
April 11, 2023 08:46
a38d23b to
f38f09c
Compare
LightOfHeaven1994
force-pushed
the
fix-tests
branch
8 times, most recently
from
May 29, 2023 14:51
fd49024 to
961fde2
Compare
mshriver
marked this pull request as ready for review
July 28, 2026 18:02
There was a problem hiding this comment.
Hey - I've found 1 issue, and left some high level feedback:
- The
TESTING_PAGE_URLvalue is now updated to thepatternfly-react-main.surge.shhost in many files; consider centralizing this base URL (or deriving it from a single helper/config) to make future host changes less error-prone. - Several tests were weakened or removed entirely (e.g.
test_compound_expandable_tableno longer asserts expanded table content,test_switch_fillno longer checksselected,chips_viewtests were deleted); if these scenarios are no longer supported in the example pages, it may be worth updating the tests to validate the new behavior rather than dropping the assertions so that regressions in widget behavior are still caught.
Prompt for AI Agents
Please address the comments from this code review:
## Overall Comments
- The `TESTING_PAGE_URL` value is now updated to the `patternfly-react-main.surge.sh` host in many files; consider centralizing this base URL (or deriving it from a single helper/config) to make future host changes less error-prone.
- Several tests were weakened or removed entirely (e.g. `test_compound_expandable_table` no longer asserts expanded table content, `test_switch_fill` no longer checks `selected`, `chips_view` tests were deleted); if these scenarios are no longer supported in the example pages, it may be worth updating the tests to validate the new behavior rather than dropping the assertions so that regressions in widget behavior are still caught.
## Individual Comments
### Comment 1
<location path="testing/test_chartline.py" line_range="19-21" />
<code_context>
-pytestmark = pytest.mark.skip("No OUIA IDs provided on Patternfly testing page")
-
-
-@pytest.fixture()
-def modal(browser):
- class ModalTestView(View):
</code_context>
<issue_to_address>
**suggestion (testing):** Removing the explicit sleep may reintroduce flakiness if the line chart data loads asynchronously
The old fixture used `sleep(3)` to let the chart data settle (especially in Firefox). With the new `view` fixture we now read legends/data immediately. If the chart still populates asynchronously, this can reintroduce flakiness. Please add a proper wait (e.g., wait for the expected number of legends or for `read()` to return non-empty data) instead of a fixed sleep to keep the test stable.
</issue_to_address>Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
Collaborator
Author
|
@mshriver whaaat, 3 years ago 😄 |
Contributor
|
yep, some teams are still using it and I just released widgetastic.core 1.2.1 to handle the wait_for 2.x change to |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR is supposed to fix all unit tests that are failing right now. OUIA tests are not relevant as they were run against custom page so they were deleted. Official doc page doesn't have concrete OUIA IDs set.
But we are ready to use OUIA tests in WP5 when repo created patternfly/patternfly-react#8893 .
Summary by Sourcery
Update UI integration tests to align with the current Patternfly React demo pages and remove obsolete OUIA tests.
Bug Fixes:
Tests: