<AWT Dev> [9] Review Request: JDK-8081361 [TEST_BUG] Test java/awt/GridBagLayout/GridBagLayoutIpadXYTest/GridBagLayoutIpadXYTest fails
Alexander Scherbatiy
alexandr.scherbatiy at oracle.com
Thu Jul 2 13:31:07 UTC 2015
The fix looks good to me.
It would be useful to check that the fix that causes the change of
the JTextField size made it by purposes and not as side effect.
Thanks,
Alexander.
On 6/30/2015 12:26 PM, pooja chopra wrote:
> Hi Alexander,
> I fixed the test to match the spec as mentioned
> https://docs.oracle.com/javase/8/docs/api/java/awt/GridBagLayout.html
> that the width of the component will be at least its minimum width
> plus ipadx pixels. Similarly, the height of the component will be at
> least the minimum height plus ipady pixels.
>
> Whereas in the test it is checking for both to be equal and therefore
> test will fail for cases where component width or height is greater
> than minimum width plus ipadx pixels or minimum height plus ipady
> pixels.In the existing test the comparison is done as below :-
>
> Dimension minSize = jtf.getMinimumSize();
> if ( minSize.width + customIpadx != jtf.getSize().width ||
> minSize.height + customIpady != jtf.getSize().height )
>
> And I changed the comparison to match Spec as below :-
>
> Dimension minSize = jtf.getMinimumSize();
> if (!(minSize.width + customIpadx <= jtf.getSize().width) ||
> !(minSize.height + customIpady <= jtf.getSize().height))
>
> Regards,
> Pooja
> On 6/29/2015 4:55 PM, Alexander Scherbatiy wrote:
>>
>>
>> Hello Pooja,
>>
>> What was the fix that causes the regression?
>>
>> Thanks,
>> Alexandr.
>>
>> On 6/18/2015 12:22 PM, pooja chopra wrote:
>>> Hello,
>>> Please review a fix for issue:
>>> 8081361 [TEST_BUG] Test
>>> java/awt/GridBagLayout/GridBagLayoutIpadXYTest/GridBagLayoutIpadXYTest
>>> fails
>>>
>>> Test bug fix.
>>> https://bugs.openjdk.java.net/browse/JDK-8081361
>>>
>>> The webrev is : http://cr.openjdk.java.net/~pchopra/8081361/webrev.00/
>>>
>>> Regards,
>>> Pooja
>>
>
More information about the awt-dev
mailing list