[mevenide-dev] [jira] Resolved: (MEVENIDE-635) Automatically create src\test\java directory if it is missing when user clicks Create JUnit Tests menu item

"Milos Kleint (JIRA)" <jira-yCVjj/[email protected]> Thu, 15 May 2008 07:53:27 -0500 (CDT)
Newsgroups gmane.comp.jakarta.turbine.maven.mevenide.devel
Message-ID <7527564.1210856007218.JavaMail.haus-jira@codehaus01.managed.contegix.com>
     [ http://jira.codehaus.org/browse/MEVENIDE-635?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Milos Kleint resolved MEVENIDE-635.
-----------------------------------

       Resolution: Duplicate
    Fix Version/s:     (was: NB_3.2)
                   NB_FUTURE

ok, closing as duplicate of the mentioned netbeans.org issue.

> Automatically create src\test\java directory if it is missing when user clicks Create JUnit Tests menu item
> -----------------------------------------------------------------------------------------------------------
>
>                 Key: MEVENIDE-635
>                 URL: http://jira.codehaus.org/browse/MEVENIDE-635
>             Project: mevenide
>          Issue Type: Improvement
>          Components: mevenide2-netbeans
>    Affects Versions: NB_3.1
>         Environment: Windows XP
> NetBeans 6.1 final
> Maven 3.11 plugin
>            Reporter: Jonathan Ramsey
>            Assignee: Milos Kleint
>            Priority: Minor
>             Fix For: NB_FUTURE
>
>         Attachments: create-tests-dialog.gif, properties-dialog.gif, warning-dialog.gif
>
>
> I noticed that the Create JUnit Tests menu item didn't allow me to create a JUnit test for a class in a Maven2 project opened in NetBeans.
> Steps to reproduce:
> 1. Click File > Open Project
> 2. Choose project directory (in Open Project dialog)
> 3. Click Open Project button.
> 4. Expand project node (in Projects pane)
> 5. Expand Source Packages node.
> 6. Expand the java package.
> 7. Right click on a .java file which doesn't have an existing unit test.
> 8. Click Tools > Create JUnit Tests (on context menu)
> I get a [Warning dialog|^warning-dialog.gif] which says:
> bq.Unable to locate test package folders in project "XXXX (jar)". The project must contain a test package folder to create tests. You can designate test package folders for your project in the Sources pane of the project Properties dialog.
> The Sources pane in the project [Properties dialog|^properties-dialog.gif] doesn't provide anything to allow you to 'designate test package folders'.
> The directory structure of the project was:
> src
> src\main
> src\main\java
> The obvious missing directory is a src\test\java directory.
> I had a look at [Introduction to the Standard Directory Layout|http://maven.apache.org/guides/introduction/introduction-to-the-standard-directory-layout.html], and also did some Google searches, but I couldn't find anything which confirms if src\test\java is required or not. Maven doesn't display any warnings related to the missing src\test\java directory when building, so I guess it is optional.
> I added the src\test\java directory to get this structure:
> src
> src\main
> src\main\java
> src\test
> src\test\java
> and repeated the steps to reproduce. This time I get the expected [Create Tests dialog|^create-tests-dialog.gif].
> I thought a good usability improvement to mevenide2 would be to intercept the Create JUnit Tests menu click and automatically create the src\test\java directory if it is missing instead of displaying the (not so helpful) Warning dialog.
> If this is fixable by changing mevenide2, and you could point me in the right direction, I'm happy to try creating a test case and patch to implement the functionality.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email