Grégory Joseph ha scritto:

Try to add a dependency to junit on your project; seems weird, but I've had to do this once ... can't remember the exact reason right now.

Already have it:

<dependency>
  <groupId>junit</groupId>
  <artifactId>junit</artifactId>
  <version>4.4</version>
</dependency>


You said "After a module refactoring, I'm encountering this problem." --- you're not saying what you refactored, and how that'd have anything to do with the issue at hand.

Ok, in short, we started our project without having a parent POM inheriting from magnolia-project POM. The refactoring was to let our parent POM to inherit from magnolia-project 3.6.3 (we are still on this version).

You also don't mention is this occurs only within Eclipse or also from the command line (since you mention you use m2eclipse, suspicion is permitted ;))

It occurs both on m2eclipse than command line, the message from the command line is the following:

...
[INFO] [compiler:testCompile]
[INFO] No sources to compile
[INFO] [surefire:test]
[INFO] Surefire report directory: C:\dev\deploy\project\prisma\magnolia\modules\prisma-content\trunk\target\surefire-reports [INFO] ------------------------------------------------------------------------
[ERROR] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] There are test failures.

Please refer to C:\dev\deploy\project\prisma\magnolia\modules\prisma-content\trunk\target\surefire-reports for the individual test results.
...

The only way I manage to solve this issue is to bypass the entire surefire test plugin, which is maybe the worst thing I have ever done with maven, I know...

What about <failIfNoTests>false</failIfNoTests> property?
Can it be a solution? And in this case, which is the best place to add it?

You'd rather need to *remove* it rather than add it. It would be in the configuration of the surefire plugin.

I've tried to add

<configuration>
  <skip>false</skip>
  <failIfNoTests>false</failIfNoTests>
</configuration>

without success...

PS: the strange thing is that other projects without tests to perform are succesfully built! See below a full maven log:

my-common project is succesfully built and it has no tests!
my-content fails...

grrr...eg ;-)

....................... no ideas :-(






------------------------------ long -----------------------------------

*********************************************************************

*** PRESS A KEY TO CONTINUE...
Press any key to continue . . .
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] Building my: parent (pom)
[INFO]    task-segment: [clean, install]
[INFO] ------------------------------------------------------------------------
[INFO] [clean:clean]
[INFO] Deleting directory C:\dev\deploy\my-project\my\magnolia\modules\my-parent\trunk\target
[INFO] [cobertura:clean {execution: default}]
[INFO] [enforcer:enforce {execution: enforce}]
[INFO] Skipping Rule Enforcement.
[INFO] [setproperty:set-property {execution: currentDate}]
[INFO] Property magnoliaCurrentDate set to value 26. maggio 2009 (scope: project
)
[INFO] Property magnoliaNiceVersion set to value 1.3.0 (scope: project)
[INFO] Property magnoliaReleaseDate set to value 26. maggio 2009 (scope: project
)
[INFO] Setting property: classpath.resource.loader.class => 'org.codehaus.plexus
.velocity.ContextClassLoaderResourceLoader'.
[INFO] Setting property: velocimacro.messages.on => 'false'.
[INFO] Setting property: resource.loader => 'classpath'.
[INFO] Setting property: resource.manager.logwhenfound => 'false'.
[INFO] [remote-resources:process {execution: default}]
[INFO] [compiler:testCompile {execution: compile-tests}]
[INFO] No sources to compile
[INFO] [site:attach-descriptor]
[INFO] Preparing checkstyle:check
[INFO] Setting property: classpath.resource.loader.class => 'org.codehaus.plexus
.velocity.ContextClassLoaderResourceLoader'.
[INFO] Setting property: velocimacro.messages.on => 'false'.
[INFO] Setting property: resource.loader => 'classpath'.
[INFO] Setting property: resource.manager.logwhenfound => 'false'.
[INFO] **************************************************************
[INFO] Starting Jakarta Velocity v1.4
[INFO] RuntimeInstance initializing.
[INFO] Default Properties File: org\apache\velocity\runtime\defaults\velocity.pr
operties
[INFO] Default ResourceManager initializing. (class org.apache.velocity.runtime.
resource.ResourceManagerImpl)
[INFO] Resource Loader Instantiated: org.codehaus.plexus.velocity.ContextClassLo
aderResourceLoader
[INFO] ClasspathResourceLoader : initialization starting.
[INFO] ClasspathResourceLoader : initialization complete.
[INFO] ResourceCache : initialized. (class org.apache.velocity.runtime.resource.
ResourceCacheImpl)
[INFO] Default ResourceManager initialization complete.
[INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Literal
[INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Macro
[INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Parse
[INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Include [INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Foreach
[INFO] Created: 20 parsers.
[INFO] Velocimacro : initialization starting.
[INFO] Velocimacro : adding VMs from VM library template : VM_global_library.vm [ERROR] ResourceManager : unable to find resource 'VM_global_library.vm' in any
resource loader.
[INFO] Velocimacro : error using VM library template VM_global_library.vm : org .apache.velocity.exception.ResourceNotFoundException: Unable to find resource 'V
M_global_library.vm'
[INFO] Velocimacro :  VM library template macro registration complete.
[INFO] Velocimacro : allowInline = true : VMs can be defined inline in templates

[INFO] Velocimacro : allowInlineToOverride = false : VMs defined inline may NOT
replace previous VM definitions
[INFO] Velocimacro : allowInlineLocal = false : VMs defined inline will be glob
al in scope if allowed.
[INFO] Velocimacro : initialization complete.
[INFO] Velocity successfully started.
[INFO] [checkstyle:checkstyle]
[INFO] [checkstyle:check {execution: default}]
[INFO] [install:install]
[INFO] Installing C:\dev\deploy\my-project\my\magnolia\modules\my-pa
rent\trunk\pom.xml to C:\Documents and Settings\matteo\.m2\repository\ch\rtsi\my\my-parent\1.3.0\my-parent-1.3.0.pom [INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESSFUL
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 6 seconds
[INFO] Finished at: Tue May 26 13:24:34 CEST 2009
[INFO] Final Memory: 24M/44M
[INFO] ------------------------------------------------------------------------
[INFO] Scanning for projects...
[INFO] Reactor build order:
[INFO]   my Magnolia module: my-common
[INFO]   env Prototype Module
[INFO]   my Magnolia module: my-content
[INFO]   my Magnolia module: my-mirror
[INFO]   my Magnolia module: my-layout
[INFO]   my Magnolia module: my-widgets
[INFO]   my Magnolia module: my-navigation
[INFO]   my Magnolia module: my-io
[INFO]   my Magnolia module: my-community
[INFO]   my Magnolia module: my-smartlink
[INFO]   my Magnolia module: my-jukebox
[INFO]   my Magnolia module: my-wrapper
[INFO]   my-webapp
[INFO]   my-root
[INFO] ------------------------------------------------------------------------
[INFO] Building my Magnolia module: my-common
[INFO]    task-segment: [clean, install]
[INFO] ------------------------------------------------------------------------
[INFO] [clean:clean]
[INFO] Deleting directory C:\dev\deploy\my-project\my\magnolia\modules\my-common\trunk\target
[INFO] [cobertura:clean {execution: default}]
[INFO] [enforcer:enforce {execution: enforce}]
[INFO] Skipping Rule Enforcement.
[INFO] [setproperty:set-property {execution: currentDate}]
[INFO] Property magnoliaCurrentDate set to value 26. maggio 2009 (scope: project
)
[INFO] Property magnoliaNiceVersion set to value 1.3.6 (scope: project)
[INFO] Property magnoliaReleaseDate set to value 26. maggio 2009 (scope: project
)
[INFO] Setting property: classpath.resource.loader.class => 'org.codehaus.plexus
.velocity.ContextClassLoaderResourceLoader'.
[INFO] Setting property: velocimacro.messages.on => 'false'.
[INFO] Setting property: resource.loader => 'classpath'.
[INFO] Setting property: resource.manager.logwhenfound => 'false'.
[INFO] [remote-resources:process {execution: default}]
[INFO] [resources:resources]
[INFO] Using encoding: 'UTF-8' to copy filtered resources.
[INFO] [compiler:compile]
[INFO] Compiling 39 source files to C:\dev\deploy\my-project\my\magnolia
\modules\my-common\trunk\target\classes
[INFO] [compiler:testCompile {execution: compile-tests}]
[INFO] No sources to compile
[INFO] [resources:testResources]
[INFO] Using encoding: 'UTF-8' to copy filtered resources.
[INFO] [compiler:testCompile]
[INFO] No sources to compile
[INFO] [surefire:test]
[INFO] Surefire report directory: C:\dev\deploy\my-project\my\magnolia\m
odules\my-common\trunk\target\surefire-reports

-------------------------------------------------------
 T E S T S
-------------------------------------------------------
There are no tests to run.

Results :

Tests run: 0, Failures: 0, Errors: 0, Skipped: 0

[INFO] [jar:jar]
[INFO] Building jar: C:\dev\deploy\my-project\my\magnolia\modules\my
-common\trunk\target\my-common-1.3.6.jar
[INFO] Preparing checkstyle:check
[INFO] Setting property: classpath.resource.loader.class => 'org.codehaus.plexus
.velocity.ContextClassLoaderResourceLoader'.
[INFO] Setting property: velocimacro.messages.on => 'false'.
[INFO] Setting property: resource.loader => 'classpath'.
[INFO] Setting property: resource.manager.logwhenfound => 'false'.
[INFO] **************************************************************
[INFO] Starting Jakarta Velocity v1.4
[INFO] RuntimeInstance initializing.
[INFO] Default Properties File: org\apache\velocity\runtime\defaults\velocity.pr
operties
[INFO] Default ResourceManager initializing. (class org.apache.velocity.runtime.
resource.ResourceManagerImpl)
[INFO] Resource Loader Instantiated: org.codehaus.plexus.velocity.ContextClassLo
aderResourceLoader
[INFO] ClasspathResourceLoader : initialization starting.
[INFO] ClasspathResourceLoader : initialization complete.
[INFO] ResourceCache : initialized. (class org.apache.velocity.runtime.resource.
ResourceCacheImpl)
[INFO] Default ResourceManager initialization complete.
[INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Literal
[INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Macro
[INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Parse
[INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Include [INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Foreach
[INFO] Created: 20 parsers.
[INFO] Velocimacro : initialization starting.
[INFO] Velocimacro : adding VMs from VM library template : VM_global_library.vm [ERROR] ResourceManager : unable to find resource 'VM_global_library.vm' in any
resource loader.
[INFO] Velocimacro : error using VM library template VM_global_library.vm : org .apache.velocity.exception.ResourceNotFoundException: Unable to find resource 'V
M_global_library.vm'
[INFO] Velocimacro :  VM library template macro registration complete.
[INFO] Velocimacro : allowInline = true : VMs can be defined inline in templates

[INFO] Velocimacro : allowInlineToOverride = false : VMs defined inline may NOT
replace previous VM definitions
[INFO] Velocimacro : allowInlineLocal = false : VMs defined inline will be glob
al in scope if allowed.
[INFO] Velocimacro : initialization complete.
[INFO] Velocity successfully started.
[INFO] [checkstyle:checkstyle]
[INFO] [checkstyle:check {execution: default}]
[INFO] [install:install]
[INFO] Installing C:\dev\deploy\my-project\my\magnolia\modules\my-co
mmon\trunk\target\my-common-1.3.6.jar to C:\Documents and Settings\matteo\.m
2\repository\ch\rtsi\my\my-common\1.3.6\my-common-1.3.6.jar
[INFO] ------------------------------------------------------------------------
[INFO] Building RTSI Prototype Module
[INFO]    task-segment: [clean, install]
[INFO] ------------------------------------------------------------------------
[INFO] [clean:clean]
[INFO] Deleting directory C:\dev\deploy\my-project\my\magnolia\modules\r
tsi-prototype\trunk\target
[INFO] [cobertura:clean {execution: default}]
[INFO] [enforcer:enforce {execution: enforce}]
[INFO] Skipping Rule Enforcement.
[INFO] [setproperty:set-property {execution: currentDate}]
[INFO] Property magnoliaCurrentDate set to value 26. maggio 2009 (scope: project
)
[INFO] Property magnoliaNiceVersion set to value 1.1 (scope: project)
[INFO] Property magnoliaReleaseDate set to value 26. maggio 2009 (scope: project
)
[INFO] [remote-resources:process {execution: default}]
[INFO] [resources:resources]
[INFO] Using encoding: 'UTF-8' to copy filtered resources.
[INFO] [compiler:compile]
[INFO] Compiling 9 source files to C:\dev\deploy\my-project\my\magnolia\
modules\rtsi-prototype\trunk\target\classes
[INFO] [compiler:testCompile {execution: compile-tests}]
[INFO] No sources to compile
[INFO] [resources:testResources]
[INFO] Using encoding: 'UTF-8' to copy filtered resources.
[INFO] [compiler:testCompile]
[INFO] No sources to compile
[INFO] [surefire:test]
[INFO] Surefire report directory: C:\dev\deploy\my-project\my\magnolia\m
odules\rtsi-prototype\trunk\target\surefire-reports

-------------------------------------------------------
 T E S T S
-------------------------------------------------------
There are no tests to run.

Results :

Tests run: 0, Failures: 0, Errors: 0, Skipped: 0

[INFO] [jar:jar]
[INFO] Building jar: C:\dev\deploy\my-project\my\magnolia\modules\rtsi-p
rototype\trunk\target\rtsi-prototype-1.1.jar
[INFO] Preparing checkstyle:check
[INFO] [checkstyle:checkstyle]
[INFO] [checkstyle:check {execution: default}]
[INFO] [install:install]
[INFO] Installing C:\dev\deploy\my-project\my\magnolia\modules\rtsi-prot
otype\trunk\target\rtsi-prototype-1.1.jar to C:\Documents and Settings\matteo\.m
2\repository\info\magnolia\custom\rtsi\rtsi-prototype\1.1\rtsi-prototype-1.1.jar

[INFO] ------------------------------------------------------------------------
[INFO] Building my Magnolia module: my-content
[INFO]    task-segment: [clean, install]
[INFO] ------------------------------------------------------------------------
[INFO] [clean:clean]
[INFO] Deleting directory C:\dev\deploy\my-project\my\magnolia\modules\my-content\trunk\target
[INFO] [cobertura:clean {execution: default}]
[INFO] [enforcer:enforce {execution: enforce}]
[INFO] Skipping Rule Enforcement.
[INFO] [setproperty:set-property {execution: currentDate}]
[INFO] Property magnoliaCurrentDate set to value 26. maggio 2009 (scope: project
)
[INFO] Property magnoliaNiceVersion set to value 1.3.3 (scope: project)
[INFO] Property magnoliaReleaseDate set to value 26. maggio 2009 (scope: project
)
[INFO] [remote-resources:process {execution: default}]
[INFO] [resources:resources]
[INFO] Using encoding: 'UTF-8' to copy filtered resources.
[INFO] [compiler:compile]
[INFO] Compiling 30 source files to C:\dev\deploy\my-project\my\magnolia
\modules\my-content\trunk\target\classes
[INFO] [compiler:testCompile {execution: compile-tests}]
[INFO] No sources to compile
[INFO] [resources:testResources]
[INFO] Using encoding: 'UTF-8' to copy filtered resources.
[INFO] [compiler:testCompile]
[INFO] No sources to compile
[INFO] [surefire:test]
[INFO] Surefire report directory: C:\dev\deploy\my-project\my\magnolia\m
odules\my-content\trunk\target\surefire-reports
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] There are test failures.

Please refer to C:\dev\deploy\my-project\my\magnolia\modules\my-cont
ent\trunk\target\surefire-reports for the individual test results.
[INFO] ------------------------------------------------------------------------
[INFO] For more information, run Maven with the -e switch
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 24 seconds
[INFO] Finished at: Tue May 26 13:25:00 CEST 2009
[INFO] Final Memory: 44M/79M
[INFO] ------------------------------------------------------------------------
*********************************************************************
*** DEPLOY PROCEDURE FINISHED
*********************************************************************

C:\dev\deploy>


----------------------------------------------------------------
For list details see
http://www.magnolia-cms.com/home/community/mailing-lists.html
To unsubscribe, E-mail to: <user-list-unsubscr...@magnolia-cms.com>
----------------------------------------------------------------

Reply via email to