Re: [9] Review Request: 8004693 TEST_BUG: java/awt/KeyboardFocusmanager/DefaultPolicyChange/DefaultPolicyChange_Swing.java fails

2016-09-13 Thread Alexander Zvegintsev
Looks good to me. On 5/30/16 7:39 PM, Sergey Bylokhov wrote: Hello. Please review the fix for jdk9. The test DefaultPolicyChange_Swing.java has two issues: - It uses invokeLater(), so the test usually pass before the code is executed on the EDT, because the main thread completes before. - T

Re: [9] Review Request: 8004693 TEST_BUG: java/awt/KeyboardFocusmanager/DefaultPolicyChange/DefaultPolicyChange_Swing.java fails

2016-06-10 Thread Semyon Sadetsky
On 6/9/2016 12:37 PM, Sergey Bylokhov wrote: On 08.06.16 19:53, Semyon Sadetsky wrote: Yes, but the Object#equlas() does not prohibit different class instances to be equal. The purpose of the test is to prove that existing component's FTP instances remain untouchable during the default FTP chan

Re: [9] Review Request: 8004693 TEST_BUG: java/awt/KeyboardFocusmanager/DefaultPolicyChange/DefaultPolicyChange_Swing.java fails

2016-06-09 Thread Sergey Bylokhov
On 08.06.16 19:53, Semyon Sadetsky wrote: Yes, but the Object#equlas() does not prohibit different class instances to be equal. The purpose of the test is to prove that existing component's FTP instances remain untouchable during the default FTP change regardless of the specific FTP implementatio

Re: [9] Review Request: 8004693 TEST_BUG: java/awt/KeyboardFocusmanager/DefaultPolicyChange/DefaultPolicyChange_Swing.java fails

2016-06-08 Thread Semyon Sadetsky
On 6/8/2016 5:37 PM, Sergey Bylokhov wrote: On 08.06.16 10:12, Semyon Sadetsky wrote: Since method equals() is not specified in the FTP class, you cannot make any assumption how it is implemented, it may return true for different classes instances. So in the test the policy untouchability shoul

Re: [9] Review Request: 8004693 TEST_BUG: java/awt/KeyboardFocusmanager/DefaultPolicyChange/DefaultPolicyChange_Swing.java fails

2016-06-08 Thread Sergey Bylokhov
On 08.06.16 10:12, Semyon Sadetsky wrote: Since method equals() is not specified in the FTP class, you cannot make any assumption how it is implemented, it may return true for different classes instances. So in the test the policy untouchability should be checked by ==, without any additional ass

Re: [9] Review Request: 8004693 TEST_BUG: java/awt/KeyboardFocusmanager/DefaultPolicyChange/DefaultPolicyChange_Swing.java fails

2016-06-08 Thread Semyon Sadetsky
On 6/7/2016 3:31 PM, Sergey Bylokhov wrote: On 07.06.16 12:31, Semyon Sadetsky wrote: I cannot agree with this assumption. Since the policy should not be touched for the existing components, the test should prove that the policy object instances are the same, other behavior is an error. The p

Re: [9] Review Request: 8004693 TEST_BUG: java/awt/KeyboardFocusmanager/DefaultPolicyChange/DefaultPolicyChange_Swing.java fails

2016-06-07 Thread Sergey Bylokhov
On 07.06.16 12:31, Semyon Sadetsky wrote: I cannot agree with this assumption. Since the policy should not be touched for the existing components, the test should prove that the policy object instances are the same, other behavior is an error. The policy will be the same if two policies will re

Re: [9] Review Request: 8004693 TEST_BUG: java/awt/KeyboardFocusmanager/DefaultPolicyChange/DefaultPolicyChange_Swing.java fails

2016-06-07 Thread Semyon Sadetsky
On 6/7/2016 11:48 AM, Sergey Bylokhov wrote: On 07.06.16 10:23, Semyon Sadetsky wrote: Sergey, - You need to compare with the original policy by reference. Only by that you may prove that the original policies were not affected. I do not see the reason why the equal cannot be used, if some

Re: [9] Review Request: 8004693 TEST_BUG: java/awt/KeyboardFocusmanager/DefaultPolicyChange/DefaultPolicyChange_Swing.java fails

2016-06-07 Thread Sergey Bylokhov
On 07.06.16 10:23, Semyon Sadetsky wrote: Sergey, - You need to compare with the original policy by reference. Only by that you may prove that the original policies were not affected. I do not see the reason why the equal cannot be used, if some policy will override equal and return true then

Re: [9] Review Request: 8004693 TEST_BUG: java/awt/KeyboardFocusmanager/DefaultPolicyChange/DefaultPolicyChange_Swing.java fails

2016-06-07 Thread Semyon Sadetsky
Sergey, - You need to compare with the original policy by reference. Only by that you may prove that the original policies were not affected. - Please remove the printouts of policies objects before and after the default policy change. It looks too verbose. - It would be nice to have a chec

Re: [9] Review Request: 8004693 TEST_BUG: java/awt/KeyboardFocusmanager/DefaultPolicyChange/DefaultPolicyChange_Swing.java fails

2016-06-06 Thread Alexander Stepanov
Hello Sergey, The fix looks good (not a reviewer). Thanks, Alexander On 5/30/2016 7:39 PM, Sergey Bylokhov wrote: Hello. Please review the fix for jdk9. The test DefaultPolicyChange_Swing.java has two issues: - It uses invokeLater(), so the test usually pass before the code is executed on t

Re: [9] Review Request: 8004693 TEST_BUG: java/awt/KeyboardFocusmanager/DefaultPolicyChange/DefaultPolicyChange_Swing.java fails

2016-06-06 Thread Yuri Nesterenko
+1 -yan On 05/30/2016 07:39 PM, Sergey Bylokhov wrote: Hello. Please review the fix for jdk9. The test DefaultPolicyChange_Swing.java has two issues: - It uses invokeLater(), so the test usually pass before the code is executed on the EDT, because the main thread completes before. - The te

[9] Review Request: 8004693 TEST_BUG: java/awt/KeyboardFocusmanager/DefaultPolicyChange/DefaultPolicyChange_Swing.java fails

2016-05-30 Thread Sergey Bylokhov
Hello. Please review the fix for jdk9. The test DefaultPolicyChange_Swing.java has two issues: - It uses invokeLater(), so the test usually pass before the code is executed on the EDT, because the main thread completes before. - The test fetches the FocusTraversalPolicy from the current Keybo