RFR: 8287912: GTK L&F : Background of tree icons are red [v2]

Abhishek Kumar duke at openjdk.org
Mon Sep 5 16:55:17 UTC 2022


On Mon, 5 Sep 2022 07:08:13 GMT, Prasanta Sadhukhan <psadhukhan at openjdk.org> wrote:

>> For me, test is not failing without the fix.
>> Also, if you test entire width and fail if it is not red, it might encounter black pixel of text font too and might fail, so I think it's better to check width/2 to width -1 and not entire width.
>
> Also, it's might be better to write the image in case of failure so that it gives an idea why it failed.

> For me, test is not failing without the fix. Also, if you test entire width and fail if it is not red, it might encounter black pixel of text font too and might fail, so I think it's better to check width/2 to width -1 and not entire width.

Test was not failing without the fix because the second argument of getRGB method is height/2, and for that pixel value the returned color is red. 
Changing the argument from height/2 to height/4 will fail the test without the fix otherwise it will pass the test.

Also writing the image in case of failure.

-------------

PR: https://git.openjdk.org/jdk/pull/10112



More information about the client-libs-dev mailing list