You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jetspeed-dev@portals.apache.org by Chris Kimpton <ki...@yahoo.com> on 2002/04/06 11:45:13 UTC

Running unittest target - errors in TestRegistryCategories

Hi,

I am getting errors in this junit test.

Mainly due to it finding less than its expecting - has this been
working recently?

For example, it expects 6 portlets with category 'rss'- but I can
only find 2 in the portlets.xreg and demo-portlets.xreg files - and
this is what the test is finding...

I plan to change it to match what I am finding in the registry files.

OK?

Once I get clean test runs on these, I plan to move the junit test
classes into a parallel test source tree in src/test, rather than
src/java... to match the maven standard.

Chris

=====
------------------------------------------
http://www.soccer2002.org.uk

__________________________________________________
Do You Yahoo!?
Yahoo! Tax Center - online filing with TurboTax
http://taxes.yahoo.com/

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: Running unittest target - errors in TestRegistryCategories

Posted by Paul Spencer <pa...@apache.org>.
Chris,
Chris Kimpton wrote:

> Hi,
> 
> --- Paul Spencer <pa...@apache.org> wrote:
> 
>>Chris and David,
>>I just did a cvs update.  Unittest run successfully.  I ran it from
>>the 
>>jetspeed build directory, not via maven.
>>
>>
> 
> Thanks.
> 
> I just ran the tests in my actual workarea (the one I am doing
> turbine/torque upgrade in) - and that worked!!
> 
> When I run the tests_tomcat_40 (with 4.0.1) - I get errors on
> startup/close about serializing session attributes - I seem to
> remember David mentioning this recently  - but I can't find anything
> in the archives.



Tomcat is trying to serialize active sessions.  The short story is: 
tomcat is trying to serialize the psml document tree.  I started looking 
into this and determined it was a big "can of worms" that I did not have 
time to solve.

> 
> Any tips with the tomcat_32 tests - it seems to get into an infinite
> loop waiting for something to startup.  I am using tomcat 3.2.4.


I have not tried this.  Make sure the property tomcat.home.32 is point 
to tomcat 3.2.

> 
> Chris
> 

Paul Spencer


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: Running unittest target - errors in TestRegistryCategories

Posted by Chris Kimpton <ki...@yahoo.com>.
Hi,

--- Paul Spencer <pa...@apache.org> wrote:
> Chris and David,
> I just did a cvs update.  Unittest run successfully.  I ran it from
> the 
> jetspeed build directory, not via maven.
> 

Thanks.

I just ran the tests in my actual workarea (the one I am doing
turbine/torque upgrade in) - and that worked!!

When I run the tests_tomcat_40 (with 4.0.1) - I get errors on
startup/close about serializing session attributes - I seem to
remember David mentioning this recently  - but I can't find anything
in the archives.

Any tips with the tomcat_32 tests - it seems to get into an infinite
loop waiting for something to startup.  I am using tomcat 3.2.4.

Chris

=====
------------------------------------------
http://www.soccer2002.org.uk

__________________________________________________
Do You Yahoo!?
Yahoo! Tax Center - online filing with TurboTax
http://taxes.yahoo.com/

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: Running unittest target - errors in TestRegistryCategories

Posted by Paul Spencer <pa...@apache.org>.
Chris and David,
I just did a cvs update.  Unittest run successfully.  I ran it from the 
jetspeed build directory, not via maven.

Paul Spencer

David Sean Taylor wrote:

> Chris,
> 
> Could you please get a fresh cvs co and try again before doing so.
> The test runs fine for me.
> 
> Im running 'build unittest' from the old build. 
> Not sure how to run it from maven.
> 
> Here is what I get from the TestRegistryCategories unit test:
> 
>     [junit] Running
> org.apache.jetspeed.services.registry.TestRegistryCategories
> 
>     [junit] Group: [Jetspeed]
>     [junit] ....Cat: [rss]
>     [junit] ........Apacheweek
>     [junit] ........Mozilla
>     [junit] ........XMLHack
>     [junit] ........AdminInfo
>     [junit] ........RSS
>     [junit] ........Jetspeed
>     [junit] [RSS] count = 6
>     [junit] ------------------
>     [junit] [Everything] count = 106
>     [junit] ------------------
>     [junit] [General] count = 8
>     [junit] ------------------
>     [junit] [base][xml.rss] count = 0
>     [junit] ------------------
>     [junit] [] count = 106
>     [junit] ------------------
>     [junit] [][] count = 106
>     [junit] ------------------
>     [junit] [Jetspeed][] count = 106
>     [junit] ------------------
>     [junit] [news] count = 4
>     [junit] ------------------
>     [junit] Tests run: 1, Failures: 0, Errors: 0, Time elapsed: 0.19 sec
>     [junit] Testsuite:
> org.apache.jetspeed.services.registry.TestRegistryCategor
> ies
>     [junit] Tests run: 1, Failures: 0, Errors: 0, Time elapsed: 0.19 sec
>     [junit]
>     [junit] Testcase: testCategories took 0.19 sec
> 
> Regards,
> 
> David
> 
> 
>>-----Original Message-----
>>From: Chris Kimpton [mailto:kimptoc_mail@yahoo.com] 
>>Sent: Saturday, April 06, 2002 1:45 AM
>>To: jetspeed-dev@jakarta.apache.org
>>Subject: Running unittest target - errors in TestRegistryCategories
>>
>>
>>Hi,
>>
>>I am getting errors in this junit test.
>>
>>Mainly due to it finding less than its expecting - has this 
>>been working recently?
>>
>>For example, it expects 6 portlets with category 'rss'- but I 
>>can only find 2 in the portlets.xreg and demo-portlets.xreg 
>>files - and this is what the test is finding...
>>
>>I plan to change it to match what I am finding in the registry files.
>>
>>OK?
>>
>>Once I get clean test runs on these, I plan to move the junit 
>>test classes into a parallel test source tree in src/test, 
>>rather than src/java... to match the maven standard.
>>
>>Chris
>>
>>=====
>>------------------------------------------
>>http://www.soccer2002.org.uk
>>
>>__________________________________________________
>>Do You Yahoo!?
>>Yahoo! Tax Center - online filing with TurboTax 
>>
> http://taxes.yahoo.com/
> 
> --
> To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> For additional commands, e-mail:
> <ma...@jakarta.apache.org>
> 
> 
> 
> --
> To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>
> 
> 



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: Running unittest target - errors in TestRegistryCategories

Posted by Chris Kimpton <ki...@yahoo.com>.
Hi,

--- David Sean Taylor <da...@bluesunrise.com> wrote:
> Chris,
> 
> Could you please get a fresh cvs co and try again before doing so.
> The test runs fine for me.

Oh.  I've just done a completely fresh co and it worked!

> 
> Im running 'build unittest' from the old build. 
> Not sure how to run it from maven.

It doesn't work through maven yet - it needs to be wired together - I
will do that as part of my work on this.

Chris

=====
------------------------------------------
http://www.soccer2002.org.uk

__________________________________________________
Do You Yahoo!?
Yahoo! Tax Center - online filing with TurboTax
http://taxes.yahoo.com/

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: Running unittest target - errors in TestRegistryCategories

Posted by David Sean Taylor <da...@bluesunrise.com>.
> In another copy of jetspeed that does work with the tests - the
> loading is reversed...
> 
> What defines the order in which portlets.xreg and demo-portlets.xreg
> are loaded...

Directory traversal order is pretty much random, esp. over different
operating systems.
Ok it's the same problem as import, need to resolve the references.
Will get a fix in this week for this bug and the import bug



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: Running unittest target - errors in TestRegistryCategories

Posted by Chris Kimpton <ki...@yahoo.com>.
Hi,

--- David Sean Taylor <da...@bluesunrise.com> wrote:
> 
> These 4 are out of the demo-portlets.xreg. They do not have
> category
> entries themselves.
> They are portlet refs to an abstract portlet that has the category:
> 
> > >     [junit] ........Apacheweek
> > >     [junit] ........Mozilla
> > >     [junit] ........XMLHack
> > >     [junit] ........AdminInfo
> 
> When the registry entries are loaded, category resolution follow
> parent-refs.
> In order for that to happen, the Registry entries themselves must
> call
> the Registry service.
> At least that was the only way I could get it to work.
> 
> And these 2 are from portlets.xreg:
> 
> >     [junit] ........AdminInfo
> >     [junit] ........RSS
> 
> Check your jetspeed.log under webapp/WEB-INF/log.
> There may be a problem with the way Im calling the Registry service
> before its actually initialized.
> If so let me know and I will have to figure out a different way to
> discover the Turbine service that Im in 
> (sigh)
> 

There don't seem to be any obvious errors - but it does load the ref
portlets first - before the RSS portlet - could that mean that it
fails to inherit the category?

In another copy of jetspeed that does work with the tests - the
loading is reversed...

What defines the order in which portlets.xreg and demo-portlets.xreg
are loaded...

Chris

=====
------------------------------------------
http://www.soccer2002.org.uk

__________________________________________________
Do You Yahoo!?
Yahoo! Tax Center - online filing with TurboTax
http://taxes.yahoo.com/

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: Running unittest target - errors in TestRegistryCategories

Posted by David Sean Taylor <da...@bluesunrise.com>.
Chris,

I would really hope that cvs is consistent about the content of the
repository, regardless of who logs on.
Anyway, I believe the problem has to do with the way turbine services
are loaded, and not cvs...
(btw Im loggin on via ssh mindterm)

These 4 are out of the demo-portlets.xreg. They do not have category
entries themselves.
They are portlet refs to an abstract portlet that has the category:

> >     [junit] ........Apacheweek
> >     [junit] ........Mozilla
> >     [junit] ........XMLHack
> >     [junit] ........AdminInfo

When the registry entries are loaded, category resolution follow
parent-refs.
In order for that to happen, the Registry entries themselves must call
the Registry service.
At least that was the only way I could get it to work.

And these 2 are from portlets.xreg:

>     [junit] ........AdminInfo
>     [junit] ........RSS

Check your jetspeed.log under webapp/WEB-INF/log.
There may be a problem with the way Im calling the Registry service
before its actually initialized.
If so let me know and I will have to figure out a different way to
discover the Turbine service that Im in 
(sigh)

David

> -----Original Message-----
> From: Chris Kimpton [mailto:kimptoc_mail@yahoo.com] 
> Sent: Saturday, April 06, 2002 9:48 AM
> To: Jetspeed Developers List
> Subject: RE: Running unittest target - errors in 
> TestRegistryCategories
> 
> 
> Hi,
> 
> --- David Sean Taylor <da...@bluesunrise.com> wrote:
> > Chris,
> > 
> > Could you please get a fresh cvs co and try again before 
> doing so. The 
> > test runs fine for me.
> > 
> 
> Spoke too soon.
> 
> It works with a fresh checkout via pserver (ie read-only).
> 
> But if I do a fresh checkout via ssh ( :ext:cvs.apache.org , 
> the writeable one), it has problems - only 2 entries found.
> 
> > 
> > Here is what I get from the TestRegistryCategories unit test:
> > 
> >     [junit] Running 
> > org.apache.jetspeed.services.registry.TestRegistryCategories
> > 
> >     [junit] Group: [Jetspeed]
> >     [junit] ....Cat: [rss]
> >     [junit] ........Apacheweek
> >     [junit] ........Mozilla
> >     [junit] ........XMLHack
> >     [junit] ........AdminInfo
> >     [junit] ........RSS
> >     [junit] ........Jetspeed
> >     [junit] [RSS] count = 6
> 
> 
> 
> This is what I get:
> 
>     [junit] Running 
> org.apache.jetspeed.services.registry.TestRegistryCategories
>     [junit] Group: [Jetspeed]
>     [junit] ....Cat: [rss]
>     [junit] ........AdminInfo
>     [junit] ........RSS
>     [junit] [RSS] count = 2
>     [junit] ------------------
>     [junit] Tests run: 1, Failures: 1, Errors: 0, Time 
> elapsed: 0.03 sec
>     [junit] Testsuite: 
> org.apache.jetspeed.services.registry.TestRegistryCategories
>     [junit] Tests run: 1, Failures: 1, Errors: 0, Time 
> elapsed: 0.03 sec
>     [junit]
>     [junit] Testcase: testCategories took 0.03 sec
>     [junit]     FAILED
>     [junit] null
>     [junit] junit.framework.AssertionFailedError
>     [junit]     at junit.framework.Assert.fail(Assert.java:51)
>     [junit]     at junit.framework.Assert.assertTrue(Assert.java:38)
>     [junit]     at junit.framework.Assert.assertTrue(Assert.java:45)
>     [junit]     at
> org.apache.jetspeed.services.registry.TestRegistryCategories.t
> estCategories(TestR
> egistryCategories.java:96)
>     [junit]     at java.lang.reflect.Method.invoke(Native Method)
>     [junit]     at
> junit.framework.TestCase.runTest(TestCase.java:166)
>     [junit]     at
> junit.framework.TestCase.runBare(TestCase.java:140)
> 
> 
> I am running on XP/ jdk1.3.1_02.
> 
> Chris
> 
> =====
> ------------------------------------------
> http://www.soccer2002.org.uk
> 
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Tax Center - online filing with TurboTax 
http://taxes.yahoo.com/

--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: Running unittest target - errors in TestRegistryCategories

Posted by Chris Kimpton <ki...@yahoo.com>.
Hi,

--- David Sean Taylor <da...@bluesunrise.com> wrote:
> Chris,
> 
> Could you please get a fresh cvs co and try again before doing so.
> The test runs fine for me.
> 

Spoke too soon.

It works with a fresh checkout via pserver (ie read-only).

But if I do a fresh checkout via ssh ( :ext:cvs.apache.org , the
writeable one), it has problems - only 2 entries found.

> 
> Here is what I get from the TestRegistryCategories unit test:
> 
>     [junit] Running
> org.apache.jetspeed.services.registry.TestRegistryCategories
> 
>     [junit] Group: [Jetspeed]
>     [junit] ....Cat: [rss]
>     [junit] ........Apacheweek
>     [junit] ........Mozilla
>     [junit] ........XMLHack
>     [junit] ........AdminInfo
>     [junit] ........RSS
>     [junit] ........Jetspeed
>     [junit] [RSS] count = 6



This is what I get:

    [junit] Running
org.apache.jetspeed.services.registry.TestRegistryCategories
    [junit] Group: [Jetspeed]
    [junit] ....Cat: [rss]
    [junit] ........AdminInfo
    [junit] ........RSS
    [junit] [RSS] count = 2
    [junit] ------------------
    [junit] Tests run: 1, Failures: 1, Errors: 0, Time elapsed: 0.03
sec
    [junit] Testsuite:
org.apache.jetspeed.services.registry.TestRegistryCategories
    [junit] Tests run: 1, Failures: 1, Errors: 0, Time elapsed: 0.03
sec
    [junit]
    [junit] Testcase: testCategories took 0.03 sec
    [junit]     FAILED
    [junit] null
    [junit] junit.framework.AssertionFailedError
    [junit]     at junit.framework.Assert.fail(Assert.java:51)
    [junit]     at junit.framework.Assert.assertTrue(Assert.java:38)
    [junit]     at junit.framework.Assert.assertTrue(Assert.java:45)
    [junit]     at
org.apache.jetspeed.services.registry.TestRegistryCategories.testCategories(TestR
egistryCategories.java:96)
    [junit]     at java.lang.reflect.Method.invoke(Native Method)
    [junit]     at
junit.framework.TestCase.runTest(TestCase.java:166)
    [junit]     at
junit.framework.TestCase.runBare(TestCase.java:140)


I am running on XP/ jdk1.3.1_02.

Chris

=====
------------------------------------------
http://www.soccer2002.org.uk

__________________________________________________
Do You Yahoo!?
Yahoo! Tax Center - online filing with TurboTax
http://taxes.yahoo.com/

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: Running unittest target - errors in TestRegistryCategories

Posted by David Sean Taylor <da...@bluesunrise.com>.
Chris,

Could you please get a fresh cvs co and try again before doing so.
The test runs fine for me.

Im running 'build unittest' from the old build. 
Not sure how to run it from maven.

Here is what I get from the TestRegistryCategories unit test:

    [junit] Running
org.apache.jetspeed.services.registry.TestRegistryCategories

    [junit] Group: [Jetspeed]
    [junit] ....Cat: [rss]
    [junit] ........Apacheweek
    [junit] ........Mozilla
    [junit] ........XMLHack
    [junit] ........AdminInfo
    [junit] ........RSS
    [junit] ........Jetspeed
    [junit] [RSS] count = 6
    [junit] ------------------
    [junit] [Everything] count = 106
    [junit] ------------------
    [junit] [General] count = 8
    [junit] ------------------
    [junit] [base][xml.rss] count = 0
    [junit] ------------------
    [junit] [] count = 106
    [junit] ------------------
    [junit] [][] count = 106
    [junit] ------------------
    [junit] [Jetspeed][] count = 106
    [junit] ------------------
    [junit] [news] count = 4
    [junit] ------------------
    [junit] Tests run: 1, Failures: 0, Errors: 0, Time elapsed: 0.19 sec
    [junit] Testsuite:
org.apache.jetspeed.services.registry.TestRegistryCategor
ies
    [junit] Tests run: 1, Failures: 0, Errors: 0, Time elapsed: 0.19 sec
    [junit]
    [junit] Testcase: testCategories took 0.19 sec

Regards,

David

> -----Original Message-----
> From: Chris Kimpton [mailto:kimptoc_mail@yahoo.com] 
> Sent: Saturday, April 06, 2002 1:45 AM
> To: jetspeed-dev@jakarta.apache.org
> Subject: Running unittest target - errors in TestRegistryCategories
> 
> 
> Hi,
> 
> I am getting errors in this junit test.
> 
> Mainly due to it finding less than its expecting - has this 
> been working recently?
> 
> For example, it expects 6 portlets with category 'rss'- but I 
> can only find 2 in the portlets.xreg and demo-portlets.xreg 
> files - and this is what the test is finding...
> 
> I plan to change it to match what I am finding in the registry files.
> 
> OK?
> 
> Once I get clean test runs on these, I plan to move the junit 
> test classes into a parallel test source tree in src/test, 
> rather than src/java... to match the maven standard.
> 
> Chris
> 
> =====
> ------------------------------------------
> http://www.soccer2002.org.uk
> 
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Tax Center - online filing with TurboTax 
http://taxes.yahoo.com/

--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>