Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[cdt-dev] Problem running junit plugin tests with CDT parent pom: No tests found

Hi,

I'm currently trying to build some of my plugins with the CDT parent pom.
excerpt from the build log

[INFO] --- tycho-surefire-plugin:1.6.0:test (default-test) @
org.eclipse.cdt.cmake.is.core.tests ---
[INFO] Expected eclipse log file:
/home/15knots/devel/fremd/cdt/cmake/org.eclipse.cdt.cmake.is.core.tests/target/work/data/.metadata/.log
[INFO] Command line:
    [/usr/lib64/jvm/java-1.8.0-openjdk-1.8.0/jre/bin/java,
-Dosgi.noShutdown=false, -Dosgi.os=linux, -Dosgi.ws=gtk,
-Dosgi.arch=x86_64, -javaagent:/home/15knots/.cache.
..
Results:
Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
...
[ERROR] Failed to execute goal
org.eclipse.tycho:tycho-surefire-plugin:1.6.0:test (default-test) on
project org.eclipse.cdt.cmake.is.core.tests: No tests found. -> [Help
1]

In the metadate/.log I see the following

BootLoader constants: OS=linux, ARCH=x86_64, WS=gtk, NL=de_DE
Framework arguments:  -application
org.eclipse.tycho.surefire.osgibooter.headlesstest -testproperties
/home/15knots/devel/fremd/cdt/cmake/org.eclipse.cdt.cmake.is.core.tests/target/surefire.properties
-product org.eclipse.platform.ide -pluginCustomization
/home/15knots/devel/fremd/cdt/cmake/org.eclipse.cdt.cmake.is.core.tests/../../disable_intro_in_tests.ini
Command-line arguments:  -data
/home/15knots/devel/fremd/cdt/cmake/org.eclipse.cdt.cmake.is.core.tests/target/work/data
-application org.eclipse.tycho.surefire.osgibooter.headlesstest
-testproperties
/home/15knots/devel/fremd/cdt/cmake/org.eclipse.cdt.cmake.is.core.tests/target/surefire.properties
-product org.eclipse.platform.ide -pluginCustomization
/home/15knots/devel/fremd/cdt/cmake/org.eclipse.cdt.cmake.is.core.tests/../../disable_intro_in_tests.ini

!ENTRY org.eclipse.compare.win32 4 0 2020-02-10 20:36:27.118
!MESSAGE FrameworkEvent ERROR
!STACK 0
org.osgi.framework.BundleException: Could not resolve module:
org.eclipse.compare.win32 [225]
  Unresolved requirement: Require-Capability: eclipse.platform;
filter:="(osgi.os=win32)"

Why does eclipse require the win32 stuff? Could that be the problem?

Originally, all tests ran fine with the /maven/-surefire-plugin. Now
CDt runs them with the /tycho/-maven-plugin. Do I need to tweak my
test-plugins?

When running maven with debug output, I can the that the test classes
are at the location wher surefire expects them:

[INFO] --- tycho-surefire-plugin:1.6.0:test (default-test) @
org.eclipse.cdt.cmake.is.core.tests ---
[DEBUG] Configuring mojo
org.eclipse.tycho:tycho-surefire-plugin:1.6.0:test from plugin realm
ClassRealm[plugin>org.eclipse.tycho:tycho-surefire-plugin:1.6.0,
parent: sun.misc.Launcher$AppClassLoader@70dea4e]
[DEBUG] Configuring mojo
'org.eclipse.tycho:tycho-surefire-plugin:1.6.0:test' with basic
configurator -->
[DEBUG]   (f) appArgLine = -pluginCustomization
/home/15knots/devel/fremd/cdt/cmake/org.eclipse.cdt.cmake.is.core.tests/../../disable_intro_in_tests.ini
[DEBUG]   (f) argLine =
-javaagent:/home/15knots/.cache/m2/repository/org/jacoco/org.jacoco.agent/0.8.5/org.jacoco.agent-0.8.5-runtime.jar=destfile=/home/15knots/devel/fremd/cdt/cmake/org.eclipse.cdt.cmake.is.core.tests/../../target/jacoco.exec,append=true,includes=org.eclipse.cdt.*
-Xms256m -Xmx512m -ea
[DEBUG]   (f) deleteOsgiDataDirectory = true
[DEBUG]   (s) type = p2-installable-unit
[DEBUG]   (s) artifactId = org.eclipse.platform.feature.group
[DEBUG]   (f) dependencies = [Dependency {groupId=null,
artifactId=org.eclipse.platform.feature.group, version=null,
type=p2-installable-unit}]
[DEBUG]   (f) enableAssertions = false
[DEBUG]   (f) failIfNoTests = true
[DEBUG]   (f) includes = [**/AutomatedIntegrationSuite.*]
[DEBUG]   (f) osgiDataDirectory =
/home/15knots/devel/fremd/cdt/cmake/org.eclipse.cdt.cmake.is.core.tests/target/work/data
[DEBUG]   (f) perCoreThreadCount = true
[DEBUG]   (f) pluginArtifacts = ...
[DEBUG]   (f) product = org.eclipse.platform.ide
[DEBUG]   (f) profileName = DefaultProfile
[DEBUG]   (f) project = MavenProject:
org.eclipse.cdt:org.eclipse.cdt.cmake.is.core.tests:1.0.0-SNAPSHOT @
/home/15knots/devel/fremd/cdt/cmake/org.eclipse.cdt.cmake.is.core.tests/pom.xml
[DEBUG]   (f) redirectTestOutputToFile = false
[DEBUG]   (f) reportsDirectory =
/home/15knots/devel/fremd/cdt/cmake/org.eclipse.cdt.cmake.is.core.tests/target/surefire-reports
[DEBUG]   (f) rerunFailingTestsCount = 0
[DEBUG]   (f) runOrder = filesystem
[DEBUG]   (f) session = org.apache.maven.execution.MavenSession@2e46ffd5
[DEBUG]   (f) showEclipseLog = false
[DEBUG]   (f) skipAfterFailureCount = 0
[DEBUG]   (f) surefireProperties =
/home/15knots/devel/fremd/cdt/cmake/org.eclipse.cdt.cmake.is.core.tests/target/surefire.properties
[DEBUG]   (f) testClassesDirectory =
/home/15knots/devel/fremd/cdt/cmake/org.eclipse.cdt.cmake.is.core.tests/target/classes

Any hints?

Martin


Back to the top