Community
Participate
Working Groups
Hudson Gerrit build reports 73 test failures
(In reply to Dani Megert from comment #0) > Hudson Gerrit build reports 73 test failures Those were fom API Tools. For the pde.ui.tests we get 137 failures, see https://hudson.eclipse.org/platform/job/eclipse.pde.ui-Gerrit/981/testReport/ Vikas, the first step is to enable the pde.ui.tests. You can do this in org.eclipse.pde.ui.tests/pom.xml by just changing the test class (see comment in the file itself. Then you can push this to Gerrit and should run all tests and show you the failures that need to be addressed. I assume most are setup/dependency problems as already mentioned in bug 468461.
Made this gerrit patch to fix issues in pde.ui tests https://git.eclipse.org/r/67118
Guys you need help with this?
The 1st test that fails in the log is testStateEEProperties(org.eclipse.pde.ui.tests.target.TargetEnvironmentTestCase) Time elapsed: 0.024 sec <<< ERROR! java.lang.NullPointerException: null at org.eclipse.pde.internal.core.TargetPlatformHelper.getState(TargetPlatformHelper.java:465) at org.eclipse.pde.ui.tests.target.TargetEnvironmentTestCase.testStateEEProperties(TargetEnvironmentTestCase.java:80) Looks like fState in PluginModelManager is not initialised. So changing the settings of private static boolean DEBUG = true; public static boolean DEBUG_CLASSPATH = true; public static boolean DEBUG_MODEL = true; public static boolean DEBUG_TARGET_PROFILE = true; public static boolean DEBUG_VALIDATION = true; for more information on hudson build result page.
New Gerrit change created: https://git.eclipse.org/r/67199
(In reply to Elena Laskavaia from comment #3) > Guys you need help with this? Sure. Any help is welcome (please coordinate with Vikas). Known issues for the failures/errors are usually: - missing dependencies - tests set system properties (in test.xml and launch config) which are not set when run by Hudson - test sequence
New Gerrit change created: https://git.eclipse.org/r/67390
With the new gerrit patch i can get log statements ( thanks David ). Also for some reason when I ammend old gerrit patch, it creates a new one ( need to fix this issue at my end). However, there are some obvious log statements that I missed last time. Fixing these 2 will reduce the test errors for sure. ( from 137 to hopefully 0 :) ) 1) !MESSAGE The Plug-in Development Environment requires the PlatformAdmin service to operate. Please install the compatibility fragment 'org.eclipse.osgi.compatibility.state'. 2) !MESSAGE Plug-in at '/jobs/genie.platform/eclipse.pde.ui-Gerrit/workspace_2/ui/org.eclipse.pde.ui.tests/target/work/data/.metadata/.plugins/org.eclipse.pde.ui.tests/classic/eclipse/plugins/org.eclipse.help.ui_3.0.2' does not have an OSGi bundle manifest. To use a 2.0 style plug-in you must install the plug-in converter service. Go to Help > Install New Software and install 'Eclipse 2.0 Style Plugin Support' from 'The Eclipse Project Updates' software site.
David, can you please look at previous comment and tell us how to install those 2 components before running the test cases.
(In reply to Vikas Chandra from comment #9) > David, can you please look at previous comment and tell us how to install > those 2 components before running the test cases. Try to add it as dependency in the pom.xml. For an example see http://git.eclipse.org/c/platform/eclipse.platform.text.git/plain/org.eclipse.ui.editors.tests/pom.xml
(In reply to Dani Megert from comment #10) > (In reply to Vikas Chandra from comment #9) > > David, can you please look at previous comment and tell us how to install > > those 2 components before running the test cases. > > Try to add it as dependency in the pom.xml. For an example see > http://git.eclipse.org/c/platform/eclipse.platform.text.git/plain/org. > eclipse.ui.editors.tests/pom.xml And, if it helps, the "Eclipse 2.0 Style Plugin Support" mentioned in the second message has an IU id of org.eclipse.osgi.compatibility.plugins.feature.feature.group
https://hudson.eclipse.org/platform/job/eclipse.pde.ui-Gerrit/1027/ has 56 failures whereas 1024 has 137 failures. ( in theory looks like some improvement but cant be sure actually) However there are new types of error log. However the testcase I was targeting looks fixed (TargetEnvironmentTestCase.testStateEEProperties). Next step, I will add "Eclipse 2.0 Style Plugin Support" ( thanks David for the id). Once I get result for that, I will investigate the pending failures ( if any).
The logs in latest result says [ERROR] Cannot resolve project dependencies: [ERROR] You requested to install 'bundle org.eclipse.osgi.compatibility.plugins.feature.feature.group 0.0.0' but it could not be found If id is correct, probably the type is different.
(In reply to Vikas Chandra from comment #13) > The logs in latest result says > > [ERROR] Cannot resolve project dependencies: > [ERROR] You requested to install 'bundle > org.eclipse.osgi.compatibility.plugins.feature.feature.group 0.0.0' but it > could not be found > > If id is correct, probably the type is different. It is an eclipse-feature. But the feature consists of exactly one bundle -- guess what it's name is? :) It is org.eclipse.osgi.compatibility.plugins. [Do these tests run in your workspace? You'd have to install that bundle/feature from a repository since it is not part of our SDK.] So, I would first try changing the type to eclipse-feature or change the id to the bundle: org.eclipse.osgi.compatibility.plugins. There is still a chance it may fail in a similar way even after that change. The reason is that normally the org.eclipse.osgi.compatibility.plugins is built very close to the end, after pde.core (where are these tests?). I do not know if specification in the surefire section is enough to change build-order. If not, then I'll give you some secret sauce to control build order.
(In reply to David Williams from comment #14) > ... If not, then I'll give you some secret sauce to control build > order. Well, here's the secret sauce up front. Given at least one other bundle found it necessary, I suspect you will too. See http://git.eclipse.org/c/platform/eclipse.platform.resources.git/tree/tests/org.eclipse.core.tests.resources/pom.xml#n31 The first section controls "build order" (only required when there is no other dependency that exists between manifests.mf files. <plugin> <groupId>org.eclipse.tycho</groupId> <artifactId>target-platform-configuration</artifactId> <version>${tycho.version}</version> <configuration> <dependency-resolution> <extraRequirements> <requirement> <versionRange>0.0.0</versionRange> <type>eclipse-feature</type> <id>org.eclipse.core.tests.filesystem.feature</id> .... And this section section says to use that same think in sure fire. <plugin> <groupId>org.eclipse.tycho</groupId> <artifactId>tycho-surefire-plugin</artifactId> <version>${tycho.version}</version> <configuration> <useUIHarness>false</useUIHarness> <useUIThread>false</useUIThread> <dependencies> <dependency> <artifactId>org.eclipse.core.tests.filesystem.feature</artifactId> <type>eclipse-feature</type> </dependency> .... HTH
David, I had already changed the type to eclipse feature but it now fails with ] You requested to install 'org.eclipse.osgi.compatibility.plugins.feature.feature.group.feature.group 0.0.0' but it could not be found May be I need to strip the id to org.eclipse.osgi.compatibility.plugins.feature Doing this and running another build. Let me try this before going for the secret sauce :-)
New Gerrit change created: https://git.eclipse.org/r/67729
Looks like some issues with my gerrit setting that is either creating a new branch or a new gerrit patch when I amend my previous gerrit patch. I am working on this.
created Bug 488931 for deletion of other branches. Henceforth will work with commit 67729
From the debug statement, I found out that install location of eclipse is /jobs/genie.platform/eclipse.pde.ui-Gerrit/workspace/ui/org.eclipse.pde.ui.tests/target/work default location --Location location = Platform.getInstallLocation(); And there are only 2 plugins there org.eclipse.pde.build_3.9.200.N20160312-1500 pdebuild.jar ..... customTargets.xml packager.properties org.eclipse.jdt.debug_3.10.0.N20160312-1500 In my local setup, I get 400+ plugins.. David, any idea what is going on here?
This is for debugging LocalTargetDefinitionTests::testMissingVersionRestrictedDefaultTargetPlatform
New Gerrit change created: https://git.eclipse.org/r/69810
New Gerrit change created: https://git.eclipse.org/r/69822
Debug code for nightly test results to compare the result with the one on hudson gerrit build. http://git.eclipse.org/c/pde/eclipse.pde.ui.git/commit/?id=1a41583c0bb2c6b6b37644bb684c1672aff29a47 I checked with other tests also. Most of all ( if not all) are because of comment#20. They are 56 failing tests. I think disabling them will defeat the purpose of hudson gerrit build as plugin state tests are very important and on hudson gerrit, they wont be tested at all. Once failures fall below 10, then we can probably think of disabling them ( only on hudson gerrit).
Working on https://git.eclipse.org/r/69810 and abandoning https://git.eclipse.org/r/69822
On nightly test results container for testMissingVersionRestrictedDefaultTargetPlatform=Installation /opt/users/genie.shared/workspace/ep46N-unit-lin64/workarea/N20160404-2000/eclipse-testing/test-eclipse/eclipse Default Configuration And at that location, all relevant eclipse plugins and jars are present unlike comment#20 I will revert commit of comment#24 later today
Reverted debug code via http://git.eclipse.org/c/pde/eclipse.pde.ui.git/commit/?id=efc45f21b10e31821e2d4afd729447dc721d675d
(In reply to Vikas Chandra from comment #26) > On nightly test results > > container for testMissingVersionRestrictedDefaultTargetPlatform=Installation > /opt/users/genie.shared/workspace/ep46N-unit-lin64/workarea/N20160404-2000/ > eclipse-testing/test-eclipse/eclipse Default Configuration > > And at that location, all relevant eclipse plugins and jars are present > unlike comment#20 All I know is that in Eclipse Test Framework (used for our "production builds and tests") We install the whole SDK, then install the tests (and occasionally a few other things) and then run the tests. So all tests have the "whole SDK" present. In sure-fire (on Hudson/Gerrit) I believe it installs "the minimum amount of bundles necessary" -- usually based on "manifest.mf", a few others always required, and some people have to specify extra dependencies in pom, in sure-fire configuration. BUT, I do not think you could install "the whole SDK" as a dependency. If you tried, it would basically try to build everything else before building your bundle (conceptually). But, you could probably install/required "equinox runtime" if that's enough. It *might* also interact with "BREE". Not sure if you set the VM for sure-fire, but if not, then I think it tries to use the VM based on the BREE of the bundle you are building (which would "rule out" any prereqs that required a higher BREE). Oh, nm about BREE. I see that "useJDK" assumes "SYSTEM" by default. (So, as long as you don't change that, the Gerrit/Hudson jobs I'm sure are using Java 8). There sure are a lot of options for sure-fire, see https://eclipse.org/tycho/sitedocs/tycho-surefire/tycho-surefire-plugin/test-mojo.html Not sure if you can find what you need .. or, if not possible to do the type of test you are trying to do.
changed test case here http://git.eclipse.org/c/pde/eclipse.pde.ui.git/commit/?id=958938ffdd53f4e377db2da31650e2a59d5413db It tests exactly the same thing as before but now will work on hudson gerrit.
I think the best way forward is to run those tests on hudson gerrit that don't require the whole plugin model registry. I have updated the code here https://git.eclipse.org/r/69810 AllImportTests, ExportBundleTests, ClasspathContributorTest, LocalTargetDefinitionTests , WorkspaceTargetDefinitionTests test and few more tests wont run at hudson gerrit. But rest of the tests which is > 80% of the total test cases will run. That will help us spotting issues like bug 477909 earlier than now. However this patch needs lot of cleanup ( in removing debug code and also renaming files to a better name). But this is the approach I am going to take on this one. If someone has a better approach, please let me know.
https://git.eclipse.org/r/#/c/69810/14 is my proposed patch for this issue.
Gerrit change https://git.eclipse.org/r/69810 was merged to [master]. Commit: http://git.eclipse.org/c/pde/eclipse.pde.ui.git/commit/?id=42c7b18ef3d0f0265417da5d603776e08b0ef535
Resolved via comment in previous commit. ( see comment#30 for details)
https://hudson.eclipse.org/platform/job/eclipse.pde.ui-Gerrit/1192/ 436 tests run with any pde.ui gerrit change