Re: WOUnit: loading models from other frameworks
Re: WOUnit: loading models from other frameworks
- Subject: Re: WOUnit: loading models from other frameworks
- From: Henrique Prange <email@hidden>
- Date: Sat, 25 Jun 2011 15:53:07 -0300
Hi Paul,
Is the framework B in the classpath when running your tests? WOUnit rules are unable to load eomodels for bundles that are not in the classpath (in this case the test's classpath).
If framework B is in classpath, the following configuration should be enough:
public MockEditingContext ec = new MockEditingContext("Foo", "SomeModel");
Cheers,
Henrique
On 25/06/2011, at 04:03, Paul Hoadley wrote:
> On 25/06/2011, at 3:31 PM, Paul Hoadley wrote:
>
>> I am running some WOUnit tests outside Eclipse—specifically, during a Hudson build process. If I'm testing within framework A, how can I coax MockEditingContext to load a model from some framework B? Looking at the source to AbstractEditingContextRule.loadModel(String), it needs to either already be in the default model group, or in / or /Resources in the current bundle. How can I find a model in a separate framework (assuming it's in a known location, also being built by Hudson)?
>
> In framework A's Hudson build workspace, the model is at:
>
> Root/Library/Frameworks/B.framework/Resources/SomeModel.eomodeld
>
> But this doesn't work:
>
> public MockEditingContext ec = new MockEditingContext("Foo", "Root/Library/Frameworks/B.framework/Resources/SomeModel");
>
> I thought that would have done it, but I'm still getting the IllegalArgumentException at AbstractEditingContextRule.java:178. (It wouldn't be a great solution anyway, because then it wouldn't work within Eclipse. That's only the path to a model in Hudson's workspace.)
>
>
> --
> Paul.
>
> http://logicsquad.net/
>
>
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list (email@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden