Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 378137

Summary: [region] unmet test requirement
Product: [Eclipse Project] Equinox Reporter: David Williams <david_williams>
Component: ComponentsAssignee: equinox.components-inbox <equinox.components-inbox>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: tjwatson
Version: unspecified   
Target Milestone: Juno M7   
Hardware: PC   
OS: Linux   
Whiteboard:

Description David Williams CLA 2012-05-01 00:15:52 EDT
I was "testing" the test repository, to see if it was valid, and one thing I noticed was basically, for org.eclipse.sdk.tests.feature.group 4.2.0.v20120405-1855-9KCGGZ5FvGWDi4lvmJk4rDOlC9IX


Cannot complete the install because one or more required items could not be found.
Missing requirement: Equinox Region Tests 1.0.0.v20120319-1602 (org.eclipse.equinox.region.tests 1.0.0.v20120319-1602) requires 'package org.aspectj.internal.lang.annotation [1.6.3,2.0.0)' but it could not be found

So ... I'm assuming this is part of "weaving tests"? (since it says aspectj?) 
Which I think you've said elsewhere you do not have any for weaving? 
Perhaps you have no "real" tests that use it, and is in essentially dead code? 
If so, perhaps the package requirement could be marked "optional" so as to no prevent the install? 

From a repo point of view, its it easy enough to fix by adding 

http://download.eclipse.org/tools/ajdt/aspectj/update

to the list of repository sites. 

But this isn't easy or obvious to someone trying to install the tests via p2 using a "raw" SDK. 

During our own JUnit testing we (sadly) do not do anything so fancy as to use p2 to install the tests and just "unzip" the automated test suite (as far as I can tell, so far). But ... if we ever did use p2 director, as we should, this would "break" (without some adjustments ... extra repos added). 

I hope this isn't something I broke? I did not check earlier builds/repos, just 
4.2 I20120430-1800. 

So, this bug is either an early warning you may have some failing tests :) 
Or, you have requirements you don't really need? 

Could this be related to the "odd bug" mentioned in 
bug 377365 comment 15
Comment 1 David Williams CLA 2012-05-01 01:07:32 EDT
Oh, I think I see ... we deliberately remove org.aspectj.runtime from our repo, very explicitly: 

        <p2.remove.iu>
            <repository location="file://${reposource}" />
            <iu id="org.aspectj.runtime" />
            <iu id="org.aspectj.weaver" />
            <iu id="master.feature.group" />
            <iu id="master-ecf.feature.group" />
            <iu id="master-jetty.feature.group" />
            <iu id="master-equinox-weaving.feature.group" />
        </p2.remove.iu>

So ... in the interest of have a "valid repo", is there any harm leaving it in our repo? 

As I just wrote in bug 377314, 

Perhaps the intent _was_ to get it removed from our repo, but ... does not seem
like it would harm anything, if only required by our tests, and we used only
released bundles from their official release site.

Hopefully the "runtime" bundle does not require the weaver bundle?
Comment 2 Thomas Watson CLA 2012-05-01 08:34:18 EDT
I think this is related to bug 342997.  It seems that we did get the org.eclipse.equinox.region.tests bundle built for the test repo but still are missing the last step to actually run the tests ;-) (In reply to comment #1)
> Oh, I think I see ... we deliberately remove org.aspectj.runtime from our repo,
> very explicitly: 
> 
>         <p2.remove.iu>
>             <repository location="file://${reposource}" />
>             <iu id="org.aspectj.runtime" />
>             <iu id="org.aspectj.weaver" />
>             <iu id="master.feature.group" />
>             <iu id="master-ecf.feature.group" />
>             <iu id="master-jetty.feature.group" />
>             <iu id="master-equinox-weaving.feature.group" />
>         </p2.remove.iu>
> 
> So ... in the interest of have a "valid repo", is there any harm leaving it in
> our repo? 
> 
> As I just wrote in bug 377314, 
> 
> Perhaps the intent _was_ to get it removed from our repo, but ... does not seem
> like it would harm anything, if only required by our tests, and we used only
> released bundles from their official release site.

The aspectj stuff is only required by our region tests.  And it is only needed by the virgo teststubs that we included in the test project.  There has to be a way to use bundles only for our tests and not have to contribute them to the Juno repository.  I'm pretty sure we do that for other things like easymock.  Is that your suggestion here, do what we do for eazymock?

> 
> Hopefully the "runtime" bundle does not require the weaver bundle?

The "runtime" region bundle does not need aspectj.
Comment 3 David Williams CLA 2012-05-02 03:04:22 EDT
Yes, we do leave easy mock in the repo. 

From some "test builds" I did today, looks like it will be all fixed up for Wednesday's build (and we will have a valid repo for the first time, in a long time :)