This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 77181 - J2MEUNIT - don't generate tests for private methods
Summary: J2MEUNIT - don't generate tests for private methods
Status: VERIFIED FIXED
Alias: None
Product: javame
Classification: Unclassified
Component: JUnit (show other bugs)
Version: 6.x
Hardware: All All
: P2 blocker (vote)
Assignee: Jiri Prazak
URL:
Keywords:
Depends on:
Blocks: 77184
  Show dependency tree
 
Reported: 2006-05-31 20:00 UTC by Lukas Hasik
Modified: 2007-05-31 13:37 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Lukas Hasik 2006-05-31 20:00:31 UTC
060531
-the generator generates test methods even for private methods in tested class

    private void initialize() {
    }
    public void testinitialize() {
        System.out.println("initialize");
        hello.HelloMidlet instance = new hello.HelloMidlet();
        instance.initialize();
        
        //TODO review the generated test code and remove the default call to fail.
        fail("The test case is a prototype.");
    }

compilation ends with error, of course ;)

MobileApplicationJ2MEunit\src\hello\HelloMidletTest.java:16: initialize() has
private access in hello.HelloMidlet
        instance.initialize();
1 error
Comment 1 Lukas Hasik 2006-06-23 15:09:24 UTC
moving to mobility component
Comment 2 Jiri Prazak 2006-06-26 14:46:38 UTC
fixed
Comment 3 Lukas Hasik 2006-06-27 14:07:06 UTC
verified in jars from 0627
Comment 4 Lukas Hasik 2006-07-12 14:14:19 UTC
verified in 5.5 Beta2 candidate