-
Notifications
You must be signed in to change notification settings - Fork 6.2k
8364363: Modify some manual test instructions #26636
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
base: master
Are you sure you want to change the base?
Conversation
👋 Welcome back dnguyen! A progress list of the required criteria for merging this PR into |
❗ This change is not yet ready to be integrated. |
Webrevs
|
3) The test fails if you see messages about drag | ||
events for anything other than list0. | ||
The test passes if you don't. |
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.
Is it possible to automate this part? I mean, automatically flag the test as failed (after displaying a message to the tester after dragging is complete).
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.
I have gone ahead and updated the test to be automated. I tested this on macOS (where the test skips since the test only works for XToolkit) and on Ubuntu on Xorg (where the test is automated and passes with no outputted events).
Button btn = new Button("Append \'cool\'"); | ||
btn.addActionListener(e -> area.append("cool ")); | ||
add("South", btn); | ||
area = new TextArea("AWT is cool ", 3, 3, TextArea.SCROLLBARS_NONE); | ||
add("Center", area); | ||
setSize(200, 200); | ||
StringBuilder coolStr = new StringBuilder(""); | ||
// I count 15 lines with 12 cools per line | ||
for (int i = 0; i < 12 * 15; i++) { | ||
coolStr.append("cool "); | ||
} | ||
coolStr.append("!!!!!!!"); | ||
area.append(coolStr.toString()); |
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.
Is adding 12 * 15
cools not enough?
The original instructions are pretty clear: if you see the exclamation marks, then auto-scrolling works correctly; otherwise, it auto-scrolling doesn't work as expected and the tester has to click Fail.
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.
I was testing this on different OS's and on macOS the text is cut off and none of the text renders after a certain point.
This is what it looks like when I manually move the text cursor down to scroll the text area down a bit:
I suppose this is a macOS bug. On linux (X11 and Wayland), this works fine, but the test does not start with the textarea showing the exclamation marks. Instead, it starts at the top. But, all of the text renders correctly when scrolled down. When I manually append another cool
to the text area, the auto scroll and rendering of all the text works fine for all OS's.
What I think I understand now is, there is most likely a macOS bug here and the test fails on linux. I'll revert the changes to this test. I think this also means I should ProblemList this test. I will, however, try fiddling with this test to see if I can get the programmatic appending to render on macOS and figure out the source of the issue. Maybe it will work with an added delay in the beginning or something of the sort.
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.
@aivanov-jdk Is problem-listing this test the ideal solution?
When testing jtreg manual tests, some tests had unclear instructions. This PR is an attempt at updating these tests for clarity.
MouseDraggedOriginatedByScrollBarTest.java
works as expected when compared to native apps and outputs drag events even when the mouse pointer is dragged off of the scrollbar and window altogether. Events should still fire, but the previous instructions may make this confusing since it reads as if no events should be output to the textarea at all.TextAreaAppendScrollTest2.java
seems to not work when testing with the previous implementation of programmatically appending strings to the textarea. When I scroll down using the down arrow key, none of the text below would be visible when the textarea is scrolled down. However, it would show if I pressedENTER
to create a new line or manually modify the text in the textarea first. So instead, I have implemented the original reported approach to the test of adding a button to append a string to the textarea to test for automatic scrolling when the word is wrapped to a new line.Progress
Issue
Reviewing
Using
git
Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk.git pull/26636/head:pull/26636
$ git checkout pull/26636
Update a local copy of the PR:
$ git checkout pull/26636
$ git pull https://git.openjdk.org/jdk.git pull/26636/head
Using Skara CLI tools
Checkout this PR locally:
$ git pr checkout 26636
View PR using the GUI difftool:
$ git pr show -t 26636
Using diff file
Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/26636.diff
Using Webrev
Link to Webrev Comment