[ 
https://jira.codehaus.org/browse/MCOMPILER-222?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=342974#comment-342974
 ] 

Karl Heinz Marbaise commented on MCOMPILER-222:
-----------------------------------------------

Sounds like you missed to check locally via `mvn clean package`.

> plugin should fail if class package doesn't correspond to parent folder 
> structure starting with src/main/java
> -------------------------------------------------------------------------------------------------------------
>
>                 Key: MCOMPILER-222
>                 URL: https://jira.codehaus.org/browse/MCOMPILER-222
>             Project: Maven Compiler Plugin
>          Issue Type: Bug
>    Affects Versions: 3.1
>         Environment: Apache Maven 3.1.1 
> (0728685237757ffbf44136acec0402957f723d9a; 2013-09-17 08:22:22-0700)
> Maven home: /usr/local/Cellar/maven/3.1.1/libexec
> Java version: 1.7.0_60-ea, vendor: Oracle Corporation
> Java home: /Library/Java/JavaVirtualMachines/jdk1.7.0_60.jdk/Contents/Home/jre
> Default locale: en_US, platform encoding: UTF-8
> OS name: "mac os x", version: "10.9.1", arch: "x86_64", family: "mac"
>            Reporter: Ion Iovu
>         Attachments: sampleProject.zip
>
>
> Having a class com.mycompany.myproject.MyClass in a folder 
> src/main/java/org/some after the compile step we get the class file in 
> target/com/mycompany/myproject/MyClass.class
> During refactoring, forgetting to manually change the package declarations 
> has as result the false sense of refactoring completion (maven doesn't 
> complain)
> Please find attached a sample project with one class only demonstrating the 
> issue.
> Expected result:
> maven-compiler-plugin fails with a message like 'class in directory structure 
> not similar to package declaration'
> Actual result:
> maven-compiler-plugin successfully completing compilation, ignoring the 
> directory structure the .java files are in.



--
This message was sent by Atlassian JIRA
(v6.1.6#6162)

Reply via email to