You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Oleg Khaschansky (JIRA)" <ji...@apache.org> on 2006/12/20 16:51:21 UTC
[jira] Created: (HARMONY-2822) [classlib][swing]
javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns
null while RI throws NPE
[classlib][swing] javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null while RI throws NPE
------------------------------------------------------------------------------------------------------------------
Key: HARMONY-2822
URL: http://issues.apache.org/jira/browse/HARMONY-2822
Project: Harmony
Issue Type: Bug
Components: Classlib
Reporter: Oleg Khaschansky
Priority: Minor
javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null on Harmony while RI throws NPE.
Current implementation of BasicFileChooserUI.installDefaults(JFileChooser fc) simply ignores the parameter, so it doesn't throw this unspecified NPE. I suggest to treat this as a non-bug difference.
The following testcase demonstrates this behavior:
--------------------------------------------------------------------------------------
import junit.framework.TestCase;
import javax.swing.plaf.basic.BasicFileChooserUI;
import javax.swing.*;
import java.lang.reflect.InvocationTargetException;
public class Test0 extends TestCase {
public void testcase1() {
BasicFileChooserUI jm = new BasicFileChooserUI(null);
java.lang.reflect.Method mt = null;
Class cls = BasicFileChooserUI.class;
try{
mt = cls.getDeclaredMethod( "installDefaults", JFileChooser.class);
} catch(Exception e) {
e.printStackTrace();
}
mt.setAccessible(true);
Object[] obj ={null};
try {
mt.invoke(jm, obj );
fail("NPE should be thrown");
} catch ( IllegalAccessException ae) {
ae.printStackTrace();
} catch ( InvocationTargetException ie) {
}
}
}
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Updated: (HARMONY-2822) [classlib][swing]
javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns
null while RI throws NPE
Posted by "sergey krivenko (JIRA)" <ji...@apache.org>.
[ http://issues.apache.org/jira/browse/HARMONY-2822?page=all ]
sergey krivenko updated HARMONY-2822:
-------------------------------------
Attachment: Harmony-2822-BasicFileChooserUI.patch
the attached is a fix to the bug
> [classlib][swing] javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null while RI throws NPE
> ------------------------------------------------------------------------------------------------------------------
>
> Key: HARMONY-2822
> URL: http://issues.apache.org/jira/browse/HARMONY-2822
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Oleg Khaschansky
> Priority: Minor
> Attachments: Harmony-2822-BasicFileChooserUI.patch
>
>
> javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null on Harmony while RI throws NPE.
> Current implementation of BasicFileChooserUI.installDefaults(JFileChooser fc) simply ignores the parameter, so it doesn't throw this unspecified NPE. I suggest to treat this as a non-bug difference.
> The following testcase demonstrates this behavior:
> --------------------------------------------------------------------------------------
> import junit.framework.TestCase;
> import javax.swing.plaf.basic.BasicFileChooserUI;
> import javax.swing.*;
> import java.lang.reflect.InvocationTargetException;
> public class Test0 extends TestCase {
> public void testcase1() {
> BasicFileChooserUI jm = new BasicFileChooserUI(null);
> java.lang.reflect.Method mt = null;
> Class cls = BasicFileChooserUI.class;
> try{
> mt = cls.getDeclaredMethod( "installDefaults", JFileChooser.class);
> } catch(Exception e) {
> e.printStackTrace();
> }
> mt.setAccessible(true);
> Object[] obj ={null};
> try {
> mt.invoke(jm, obj );
> fail("NPE should be thrown");
> } catch ( IllegalAccessException ae) {
> ae.printStackTrace();
> } catch ( InvocationTargetException ie) {
> }
> }
> }
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Resolved: (HARMONY-2822) [classlib][swing]
javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns
null while RI throws NPE
Posted by "Mark Hindess (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HARMONY-2822?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Mark Hindess resolved HARMONY-2822.
-----------------------------------
Resolution: Fixed
Assignee: Mark Hindess
Applied patches in r496695. Please confirm they have been applied as expected.
> [classlib][swing] javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null while RI throws NPE
> ------------------------------------------------------------------------------------------------------------------
>
> Key: HARMONY-2822
> URL: https://issues.apache.org/jira/browse/HARMONY-2822
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Oleg Khaschansky
> Assigned To: Mark Hindess
> Priority: Minor
> Attachments: Harmony-2822-BasicFileChooserUI.patch, Harmony-2822-BasicFileChooserUITest.patch
>
>
> javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null on Harmony while RI throws NPE.
> Current implementation of BasicFileChooserUI.installDefaults(JFileChooser fc) simply ignores the parameter, so it doesn't throw this unspecified NPE. I suggest to treat this as a non-bug difference.
> The following testcase demonstrates this behavior:
> --------------------------------------------------------------------------------------
> import junit.framework.TestCase;
> import javax.swing.plaf.basic.BasicFileChooserUI;
> import javax.swing.*;
> import java.lang.reflect.InvocationTargetException;
> public class Test0 extends TestCase {
> public void testcase1() {
> BasicFileChooserUI jm = new BasicFileChooserUI(null);
> java.lang.reflect.Method mt = null;
> Class cls = BasicFileChooserUI.class;
> try{
> mt = cls.getDeclaredMethod( "installDefaults", JFileChooser.class);
> } catch(Exception e) {
> e.printStackTrace();
> }
> mt.setAccessible(true);
> Object[] obj ={null};
> try {
> mt.invoke(jm, obj );
> fail("NPE should be thrown");
> } catch ( IllegalAccessException ae) {
> ae.printStackTrace();
> } catch ( InvocationTargetException ie) {
> }
> }
> }
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Closed: (HARMONY-2822) [classlib][swing]
javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns
null while RI throws NPE
Posted by "Mark Hindess (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HARMONY-2822?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Mark Hindess closed HARMONY-2822.
---------------------------------
Verified.
> [classlib][swing] javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null while RI throws NPE
> ------------------------------------------------------------------------------------------------------------------
>
> Key: HARMONY-2822
> URL: https://issues.apache.org/jira/browse/HARMONY-2822
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Oleg Khaschansky
> Assigned To: Mark Hindess
> Priority: Minor
> Attachments: Harmony-2822-BasicFileChooserUI.patch, Harmony-2822-BasicFileChooserUITest.patch
>
>
> javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null on Harmony while RI throws NPE.
> Current implementation of BasicFileChooserUI.installDefaults(JFileChooser fc) simply ignores the parameter, so it doesn't throw this unspecified NPE. I suggest to treat this as a non-bug difference.
> The following testcase demonstrates this behavior:
> --------------------------------------------------------------------------------------
> import junit.framework.TestCase;
> import javax.swing.plaf.basic.BasicFileChooserUI;
> import javax.swing.*;
> import java.lang.reflect.InvocationTargetException;
> public class Test0 extends TestCase {
> public void testcase1() {
> BasicFileChooserUI jm = new BasicFileChooserUI(null);
> java.lang.reflect.Method mt = null;
> Class cls = BasicFileChooserUI.class;
> try{
> mt = cls.getDeclaredMethod( "installDefaults", JFileChooser.class);
> } catch(Exception e) {
> e.printStackTrace();
> }
> mt.setAccessible(true);
> Object[] obj ={null};
> try {
> mt.invoke(jm, obj );
> fail("NPE should be thrown");
> } catch ( IllegalAccessException ae) {
> ae.printStackTrace();
> } catch ( InvocationTargetException ie) {
> }
> }
> }
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (HARMONY-2822) [classlib][swing]
javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns
null while RI throws NPE
Posted by "Mark Hindess (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HARMONY-2822?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12464684 ]
Mark Hindess commented on HARMONY-2822:
---------------------------------------
Is the test really correct? I see two code paths which will result in a pass... one with the '// PASSED' comment and one with the "ae.printStackTrace();". The "ae.printStackTrace();" needs to go anyway since we shouldn't be verbose in tests.
> [classlib][swing] javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null while RI throws NPE
> ------------------------------------------------------------------------------------------------------------------
>
> Key: HARMONY-2822
> URL: https://issues.apache.org/jira/browse/HARMONY-2822
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Oleg Khaschansky
> Priority: Minor
> Attachments: Harmony-2822-BasicFileChooserUI.patch, Harmony-2822-BasicFileChooserUITest.patch
>
>
> javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null on Harmony while RI throws NPE.
> Current implementation of BasicFileChooserUI.installDefaults(JFileChooser fc) simply ignores the parameter, so it doesn't throw this unspecified NPE. I suggest to treat this as a non-bug difference.
> The following testcase demonstrates this behavior:
> --------------------------------------------------------------------------------------
> import junit.framework.TestCase;
> import javax.swing.plaf.basic.BasicFileChooserUI;
> import javax.swing.*;
> import java.lang.reflect.InvocationTargetException;
> public class Test0 extends TestCase {
> public void testcase1() {
> BasicFileChooserUI jm = new BasicFileChooserUI(null);
> java.lang.reflect.Method mt = null;
> Class cls = BasicFileChooserUI.class;
> try{
> mt = cls.getDeclaredMethod( "installDefaults", JFileChooser.class);
> } catch(Exception e) {
> e.printStackTrace();
> }
> mt.setAccessible(true);
> Object[] obj ={null};
> try {
> mt.invoke(jm, obj );
> fail("NPE should be thrown");
> } catch ( IllegalAccessException ae) {
> ae.printStackTrace();
> } catch ( InvocationTargetException ie) {
> }
> }
> }
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (HARMONY-2822) [classlib][swing]
javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns
null while RI throws NPE
Posted by "Sergey Krivenko (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HARMONY-2822?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12465139 ]
Sergey Krivenko commented on HARMONY-2822:
------------------------------------------
It is corect but I agree the code is a little bit clumsy. Here is a new one that could be used in test:
try {
new BasicFileChooserUI(null) {
public void installDefaults(JFileChooser fc) {
super.installDefaults(fc);
}
}.installDefaults(null);
fail("NPE should be thrown");
} catch (NullPointerException npe) {
// Passed
}
> [classlib][swing] javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null while RI throws NPE
> ------------------------------------------------------------------------------------------------------------------
>
> Key: HARMONY-2822
> URL: https://issues.apache.org/jira/browse/HARMONY-2822
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Oleg Khaschansky
> Priority: Minor
> Attachments: Harmony-2822-BasicFileChooserUI.patch, Harmony-2822-BasicFileChooserUITest.patch
>
>
> javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null on Harmony while RI throws NPE.
> Current implementation of BasicFileChooserUI.installDefaults(JFileChooser fc) simply ignores the parameter, so it doesn't throw this unspecified NPE. I suggest to treat this as a non-bug difference.
> The following testcase demonstrates this behavior:
> --------------------------------------------------------------------------------------
> import junit.framework.TestCase;
> import javax.swing.plaf.basic.BasicFileChooserUI;
> import javax.swing.*;
> import java.lang.reflect.InvocationTargetException;
> public class Test0 extends TestCase {
> public void testcase1() {
> BasicFileChooserUI jm = new BasicFileChooserUI(null);
> java.lang.reflect.Method mt = null;
> Class cls = BasicFileChooserUI.class;
> try{
> mt = cls.getDeclaredMethod( "installDefaults", JFileChooser.class);
> } catch(Exception e) {
> e.printStackTrace();
> }
> mt.setAccessible(true);
> Object[] obj ={null};
> try {
> mt.invoke(jm, obj );
> fail("NPE should be thrown");
> } catch ( IllegalAccessException ae) {
> ae.printStackTrace();
> } catch ( InvocationTargetException ie) {
> }
> }
> }
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Updated: (HARMONY-2822) [classlib][swing]
javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns
null while RI throws NPE
Posted by "sergey krivenko (JIRA)" <ji...@apache.org>.
[ http://issues.apache.org/jira/browse/HARMONY-2822?page=all ]
sergey krivenko updated HARMONY-2822:
-------------------------------------
Attachment: Harmony-2822-BasicFileChooserUITest.patch
the attached is a patch to the test
> [classlib][swing] javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null while RI throws NPE
> ------------------------------------------------------------------------------------------------------------------
>
> Key: HARMONY-2822
> URL: http://issues.apache.org/jira/browse/HARMONY-2822
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Oleg Khaschansky
> Priority: Minor
> Attachments: Harmony-2822-BasicFileChooserUI.patch, Harmony-2822-BasicFileChooserUITest.patch
>
>
> javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null on Harmony while RI throws NPE.
> Current implementation of BasicFileChooserUI.installDefaults(JFileChooser fc) simply ignores the parameter, so it doesn't throw this unspecified NPE. I suggest to treat this as a non-bug difference.
> The following testcase demonstrates this behavior:
> --------------------------------------------------------------------------------------
> import junit.framework.TestCase;
> import javax.swing.plaf.basic.BasicFileChooserUI;
> import javax.swing.*;
> import java.lang.reflect.InvocationTargetException;
> public class Test0 extends TestCase {
> public void testcase1() {
> BasicFileChooserUI jm = new BasicFileChooserUI(null);
> java.lang.reflect.Method mt = null;
> Class cls = BasicFileChooserUI.class;
> try{
> mt = cls.getDeclaredMethod( "installDefaults", JFileChooser.class);
> } catch(Exception e) {
> e.printStackTrace();
> }
> mt.setAccessible(true);
> Object[] obj ={null};
> try {
> mt.invoke(jm, obj );
> fail("NPE should be thrown");
> } catch ( IllegalAccessException ae) {
> ae.printStackTrace();
> } catch ( InvocationTargetException ie) {
> }
> }
> }
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (HARMONY-2822) [classlib][swing]
javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns
null while RI throws NPE
Posted by "Sergey Krivenko (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HARMONY-2822?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12465679 ]
Sergey Krivenko commented on HARMONY-2822:
------------------------------------------
Test passed.
> [classlib][swing] javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null while RI throws NPE
> ------------------------------------------------------------------------------------------------------------------
>
> Key: HARMONY-2822
> URL: https://issues.apache.org/jira/browse/HARMONY-2822
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Oleg Khaschansky
> Assigned To: Mark Hindess
> Priority: Minor
> Attachments: Harmony-2822-BasicFileChooserUI.patch, Harmony-2822-BasicFileChooserUITest.patch
>
>
> javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null on Harmony while RI throws NPE.
> Current implementation of BasicFileChooserUI.installDefaults(JFileChooser fc) simply ignores the parameter, so it doesn't throw this unspecified NPE. I suggest to treat this as a non-bug difference.
> The following testcase demonstrates this behavior:
> --------------------------------------------------------------------------------------
> import junit.framework.TestCase;
> import javax.swing.plaf.basic.BasicFileChooserUI;
> import javax.swing.*;
> import java.lang.reflect.InvocationTargetException;
> public class Test0 extends TestCase {
> public void testcase1() {
> BasicFileChooserUI jm = new BasicFileChooserUI(null);
> java.lang.reflect.Method mt = null;
> Class cls = BasicFileChooserUI.class;
> try{
> mt = cls.getDeclaredMethod( "installDefaults", JFileChooser.class);
> } catch(Exception e) {
> e.printStackTrace();
> }
> mt.setAccessible(true);
> Object[] obj ={null};
> try {
> mt.invoke(jm, obj );
> fail("NPE should be thrown");
> } catch ( IllegalAccessException ae) {
> ae.printStackTrace();
> } catch ( InvocationTargetException ie) {
> }
> }
> }
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (HARMONY-2822) [classlib][swing]
javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns
null while RI throws NPE
Posted by "Alexey A. Ivanov (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HARMONY-2822?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12465727 ]
Alexey A. Ivanov commented on HARMONY-2822:
-------------------------------------------
There's no need to create additional anonymous class in the test patch since Swing tests are run on bootclasspath and one can call protected methods directly.
> [classlib][swing] javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null while RI throws NPE
> ------------------------------------------------------------------------------------------------------------------
>
> Key: HARMONY-2822
> URL: https://issues.apache.org/jira/browse/HARMONY-2822
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Oleg Khaschansky
> Assigned To: Mark Hindess
> Priority: Minor
> Attachments: Harmony-2822-BasicFileChooserUI.patch, Harmony-2822-BasicFileChooserUITest.patch
>
>
> javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null on Harmony while RI throws NPE.
> Current implementation of BasicFileChooserUI.installDefaults(JFileChooser fc) simply ignores the parameter, so it doesn't throw this unspecified NPE. I suggest to treat this as a non-bug difference.
> The following testcase demonstrates this behavior:
> --------------------------------------------------------------------------------------
> import junit.framework.TestCase;
> import javax.swing.plaf.basic.BasicFileChooserUI;
> import javax.swing.*;
> import java.lang.reflect.InvocationTargetException;
> public class Test0 extends TestCase {
> public void testcase1() {
> BasicFileChooserUI jm = new BasicFileChooserUI(null);
> java.lang.reflect.Method mt = null;
> Class cls = BasicFileChooserUI.class;
> try{
> mt = cls.getDeclaredMethod( "installDefaults", JFileChooser.class);
> } catch(Exception e) {
> e.printStackTrace();
> }
> mt.setAccessible(true);
> Object[] obj ={null};
> try {
> mt.invoke(jm, obj );
> fail("NPE should be thrown");
> } catch ( IllegalAccessException ae) {
> ae.printStackTrace();
> } catch ( InvocationTargetException ie) {
> }
> }
> }
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Updated: (HARMONY-2822) [classlib][swing]
javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns
null while RI throws NPE
Posted by "Oleg Khaschansky (JIRA)" <ji...@apache.org>.
[ http://issues.apache.org/jira/browse/HARMONY-2822?page=all ]
Oleg Khaschansky updated HARMONY-2822:
--------------------------------------
Patch Info: [Patch Available]
> [classlib][swing] javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null while RI throws NPE
> ------------------------------------------------------------------------------------------------------------------
>
> Key: HARMONY-2822
> URL: http://issues.apache.org/jira/browse/HARMONY-2822
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Oleg Khaschansky
> Priority: Minor
> Attachments: Harmony-2822-BasicFileChooserUI.patch, Harmony-2822-BasicFileChooserUITest.patch
>
>
> javax.swing.plaf.basic.BasicFileChooserUI.installDefaults(null) returns null on Harmony while RI throws NPE.
> Current implementation of BasicFileChooserUI.installDefaults(JFileChooser fc) simply ignores the parameter, so it doesn't throw this unspecified NPE. I suggest to treat this as a non-bug difference.
> The following testcase demonstrates this behavior:
> --------------------------------------------------------------------------------------
> import junit.framework.TestCase;
> import javax.swing.plaf.basic.BasicFileChooserUI;
> import javax.swing.*;
> import java.lang.reflect.InvocationTargetException;
> public class Test0 extends TestCase {
> public void testcase1() {
> BasicFileChooserUI jm = new BasicFileChooserUI(null);
> java.lang.reflect.Method mt = null;
> Class cls = BasicFileChooserUI.class;
> try{
> mt = cls.getDeclaredMethod( "installDefaults", JFileChooser.class);
> } catch(Exception e) {
> e.printStackTrace();
> }
> mt.setAccessible(true);
> Object[] obj ={null};
> try {
> mt.invoke(jm, obj );
> fail("NPE should be thrown");
> } catch ( IllegalAccessException ae) {
> ae.printStackTrace();
> } catch ( InvocationTargetException ie) {
> }
> }
> }
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira