File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Java in General and the fly likes How to test inner classes Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA/OCP Java SE 7 Programmer I & II Study Guide this week in the OCPJP forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "How to test inner classes " Watch "How to test inner classes " New topic
Author

How to test inner classes

Kavita Shivani
Ranch Hand

Joined: Aug 14, 2009
Posts: 45
Hi everyone,

I wanted to know what is the general approach inner classes. In my project, I have an inner class that is private. As of now, I am fixing a defect and so for debug purpose planning to make it public class and test the method I needed to and once i figure out the issue, I am planning to make the class private and keep it that way. But i wanted to if there is a better approach and if I am missing it.

thanks,
Kavitha.
Shanky Sohar
Ranch Hand

Joined: Mar 17, 2010
Posts: 1051

if the class is a inner class.you cannot access it outside without the instance of outer class even if you make it public.

SCJP6.0,My blog Ranchers from Delhi
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to test inner classes