Skip to content
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

8260331: javax/swing/JInternalFrame/8146321/JInternalFrameIconTest.java failed with "ERROR: icon and imageIcon not same." #4048

Closed
wants to merge 1 commit into from

Conversation

@prsadhuk
Copy link
Contributor

@prsadhuk prsadhuk commented May 17, 2021

This testcase has failed intermittently in CI testing citing icon and ImageIcon images are not same.
It's been observed that the rectangle been passed to Robot.createScreenCapture was incorrect to compare the icon images but is passing because the images were not different (but the images itself was incorrect) so not reliable.

When it fails, it is seen that the icon and imageicon images captured, with height of the screenCapture which is the value of the topinset of internalFrame, is wrong and differ in some pixels at the end
icon captureRect java.awt.Rectangle[x=715,y=366,width=500,height=5]
The failed images look like (where one can see that there is some difference at the end of line)
icon image
iconImage-fail
image icon
imageicon-fail

which is not compring the icon images actually.

Rectified screenrect to correctly compare the icons. After the fix, the images being compared are these
icon image
iconImage-success
imageicon
imageicon-success

Several iterations of the modified test execution is green on all platforms. Link in JBS.
I have also verified the modified test fails without 8146321 fix.


Progress

  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue
  • Change must be properly reviewed

Issue

  • JDK-8260331: javax/swing/JInternalFrame/8146321/JInternalFrameIconTest.java failed with "ERROR: icon and imageIcon not same."

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.java.net/jdk pull/4048/head:pull/4048
$ git checkout pull/4048

Update a local copy of the PR:
$ git checkout pull/4048
$ git pull https://git.openjdk.java.net/jdk pull/4048/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 4048

View PR using the GUI difftool:
$ git pr show -t 4048

Using diff file

Download this PR as a diff file:
https://git.openjdk.java.net/jdk/pull/4048.diff

@bridgekeeper
Copy link

@bridgekeeper bridgekeeper bot commented May 17, 2021

👋 Welcome back psadhukhan! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@openjdk openjdk bot added the rfr label May 17, 2021
@openjdk
Copy link

@openjdk openjdk bot commented May 17, 2021

@prsadhuk The following label will be automatically applied to this pull request:

  • swing

When this pull request is ready to be reviewed, an "RFR" email will be sent to the corresponding mailing list. If you would like to change these labels, use the /label pull request command.

@openjdk openjdk bot added the swing label May 17, 2021
@mlbridge
Copy link

@mlbridge mlbridge bot commented May 17, 2021

Webrevs

@openjdk
Copy link

@openjdk openjdk bot commented May 17, 2021

@prsadhuk This change now passes all automated pre-integration checks.

ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details.

After integration, the commit message for the final commit will be:

8260331: javax/swing/JInternalFrame/8146321/JInternalFrameIconTest.java failed with "ERROR: icon and imageIcon not same."

Reviewed-by: azvegint

You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed.

At the time when this comment was updated there had been 38 new commits pushed to the master branch:

  • a555fd8: 8264734: Some SA classes could use better hashCode() implementation
  • 2313a21: 8266637: CHT: Add insert_and_get method
  • 7b736ec: 8266489: Enable G1 to use large pages on Windows when region size is larger than 2m
  • f422787: 8266073: Regression ~2% in Derby after 8261804
  • 02f895c: 8252685: APIs that require JavaThread should take JavaThread arguments
  • 2066f49: 8266764: [REDO] JDK-8255493 Support for pre-generated java.lang.invoke classes in CDS dynamic archive
  • 8c71144: 8265153: add time based test for ThreadMXBean.getThreadInfo() and ThreadInfo.getLockOwnerName()
  • 10cafd2: 8267153: Problemlist jdk/jfr/event/gc/collection/TestG1ParallelPhases.java to remove the noise from CI
  • f3fb5a4: 8266942: gtest/GTestWrapper.java os.iso8601_time_vm failed
  • 7ab6dc8: 6676643: Improve current C_GetAttributeValue native implementation
  • ... and 28 more: https://git.openjdk.java.net/jdk/compare/b50fc5f992c2a1bdcdc8cae4aacf2a16598d5d05...master

As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details.

➡️ To integrate this PR with the above commit message to the master branch, type /integrate in a new comment.

@openjdk openjdk bot added the ready label May 17, 2021
@prsadhuk
Copy link
Contributor Author

@prsadhuk prsadhuk commented May 17, 2021

/integrate

@openjdk openjdk bot closed this May 17, 2021
@openjdk openjdk bot added integrated and removed ready rfr labels May 17, 2021
@openjdk
Copy link

@openjdk openjdk bot commented May 17, 2021

@prsadhuk Since your change was applied there have been 39 commits pushed to the master branch:

  • a29612e: 8255661: TestHeapDumpOnOutOfMemoryError fails with EOFException
  • a555fd8: 8264734: Some SA classes could use better hashCode() implementation
  • 2313a21: 8266637: CHT: Add insert_and_get method
  • 7b736ec: 8266489: Enable G1 to use large pages on Windows when region size is larger than 2m
  • f422787: 8266073: Regression ~2% in Derby after 8261804
  • 02f895c: 8252685: APIs that require JavaThread should take JavaThread arguments
  • 2066f49: 8266764: [REDO] JDK-8255493 Support for pre-generated java.lang.invoke classes in CDS dynamic archive
  • 8c71144: 8265153: add time based test for ThreadMXBean.getThreadInfo() and ThreadInfo.getLockOwnerName()
  • 10cafd2: 8267153: Problemlist jdk/jfr/event/gc/collection/TestG1ParallelPhases.java to remove the noise from CI
  • f3fb5a4: 8266942: gtest/GTestWrapper.java os.iso8601_time_vm failed
  • ... and 29 more: https://git.openjdk.java.net/jdk/compare/b50fc5f992c2a1bdcdc8cae4aacf2a16598d5d05...master

Your commit was automatically rebased without conflicts.

Pushed as commit 39a454b.

💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored.

@prsadhuk prsadhuk deleted the JDK-8260331 branch May 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
2 participants