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

Ronald Chen commented on MNG-5369:
----------------------------------

Jörg if what you say is true, every case in my matrix should have failed.

The fact that some cases did work is the inconsistency.  Consistency can be 
fixed by flipping the success condition and make all those cases fail.
                
> Inconsistent interaction between activeProfiles and activeByDefault
> -------------------------------------------------------------------
>
>                 Key: MNG-5369
>                 URL: https://jira.codehaus.org/browse/MNG-5369
>             Project: Maven 2 & 3
>          Issue Type: Bug
>          Components: Profiles, Settings
>    Affects Versions: 3.0.4
>         Environment: Apache Maven 3.0.4 (r1232337; 2012-01-17 00:44:56-0800)
> Maven home: /home/rchen/dev/tools/apache-maven-3.0.4
> Java version: 1.6.0_26, vendor: Sun Microsystems Inc.
> Java home: /home/rchen/dev/tools/jdk1.6.0_26/jre
> Default locale: en_CA, platform encoding: UTF-8
> OS name: "linux", version: "2.6.36-020636-generic", arch: "amd64", family: 
> "unix"
>            Reporter: Ronald Chen
>         Attachments: maven-active-by-default-parent.tar.gz, 
> maven-profiles-bug.png
>
>
> I have two profiles.  One is activated by activeProfiles in settings.xml and 
> the other is activeByDefault = true
> They are both expected to be active as I am not using -P in my commands.
> The bug is there are some cases in which the activeByDefault profile is not 
> active.
> It seems like whenever both profiles are located in the same pom, the 
> activeByDefault profile is no longer active.  But moving the activeProfiles 
> profile up into a parent pom or moving the activeByDefault profile down to a 
> module both seems to work.
> Its a rather complicated to describe, so I have attached 6 sample projects 
> which illustrates various scenarios.  I've summarized the results in the 
> attached image.
> You can also run all the projects with the command:
> ls -1 | xargs --verbose -I CASE mvn -f CASE/sub-parent/project/pom.xml 
> validate -s CASE/settings.xml |grep -vP '^\[INFO\]'

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


Reply via email to