Re: Junit sometimes failes

From: Andrey Razumovsky (razumovsky.andre..mail.com)
Date: Tue Sep 15 2009 - 12:55:53 EDT

  • Next message: Kevin Menard: "Re: Junit sometimes failes"

    Seems it worked all before revision 811957. I'll try to figure out too, it
    is quite big

    2009/9/15 Kevin Menard <nirvdru..mail.com>

    > Per your suggestion, I upgraded to maven 2.2.1. That did not fix the
    > JPA tests. I think changed by JDK in JAVA_HOME from 1.5 to 1.6 and
    > that did fix the JPA issues. However, now I'm seeing these test
    > failures:
    >
    > Tests in error:
    >
    > testSelectCompound1(org.apache.cayenne.access.DataContextFlattenedAttributesTest)
    >
    > testSelectCompound2(org.apache.cayenne.access.DataContextFlattenedAttributesTest)
    >
    > I'd have to dig into it more. The stack traces are below:
    >
    >
    > -------------------------------------------------------------------------------
    > Test set: org.apache.cayenne.access.DataContextFlattenedAttributesTest
    >
    > -------------------------------------------------------------------------------
    > Tests run: 6, Failures: 0, Errors: 2, Skipped: 0, Time elapsed: 0.188
    > sec <<< FAILURE!
    >
    > testSelectCompound1(org.apache.cayenne.access.DataContextFlattenedAttributesTest)
    > Time elapsed: 0.015 sec <<< ERROR!
    > org.apache.cayenne.CayenneRuntimeException: [v.3.0-SNAPSHOT Sep 15
    > 2009 03:01:18] Query exception.
    > at
    > org.apache.cayenne.access.DataDomainQueryAction.nextQueryException(DataDomainQueryAction.java:545)
    > at
    > org.apache.cayenne.access.UnitTestDomainQueryAction.nextQueryException(UnitTestDomainQueryAction.java:36)
    > at
    > org.apache.cayenne.access.DataNode.performQueries(DataNode.java:281)
    > at
    > org.apache.cayenne.access.DataDomainQueryAction.runQuery(DataDomainQueryAction.java:418)
    > at
    > org.apache.cayenne.access.DataDomainQueryAction.access$000(DataDomainQueryAction.java:65)
    > at
    > org.apache.cayenne.access.DataDomainQueryAction$2.transform(DataDomainQueryAction.java:391)
    > at
    > org.apache.cayenne.access.DataDomain.runInTransaction(DataDomain.java:850)
    > at
    > org.apache.cayenne.access.DataDomainQueryAction.runQueryInTransaction(DataDomainQueryAction.java:388)
    > at
    > org.apache.cayenne.access.UnitTestDomainQueryAction.runQueryInTransaction(UnitTestDomainQueryAction.java:54)
    > at
    > org.apache.cayenne.access.DataDomainQueryAction.execute(DataDomainQueryAction.java:117)
    > at
    > org.apache.cayenne.access.UnitTestDomainQueryAction.execute(UnitTestDomainQueryAction.java:48)
    > at
    > org.apache.cayenne.access.UnitTestDomain.onQuery(UnitTestDomain.java:63)
    > at
    > org.apache.cayenne.util.ObjectContextQueryAction.runQuery(ObjectContextQueryAction.java:333)
    > at
    > org.apache.cayenne.util.ObjectContextQueryAction.execute(ObjectContextQueryAction.java:96)
    > at
    > org.apache.cayenne.access.DataContext.onQuery(DataContext.java:1278)
    > at
    > org.apache.cayenne.access.DataContext.performQuery(DataContext.java:1267)
    > at
    > org.apache.cayenne.access.DataContextFlattenedAttributesTest.testSelectCompound1(DataContextFlattenedAttributesTest.java:117)
    > Caused by: java.sql.SQLException: Column not found: T3.PAINTING_ID in
    > statement [SELECT t0.ARTIST_ID, t0.PAINTING_ID, t0.GALLERY_ID,
    > t0.ESTIMATED_PRICE, t1.TEXT_REVIEW, t0.PAINTING_TITLE, t2.ARTIST_NAME,
    > t3.GALLERY_NAME, t3.PAINTING_ID FROM PAINTING t0 JOIN PAINTING_INFO t1
    > ON (t0.PAINTING_ID = t1.PAINTING_ID) JOIN ARTIST t2 ON (t0.ARTIST_ID =
    > t2.ARTIST_ID) JOIN GALLERY t3 ON (t0.GALLERY_ID = t3.GALLERY_ID)]
    > at org.hsqldb.jdbc.Util.throwError(Unknown Source)
    > at org.hsqldb.jdbc.jdbcPreparedStatement.<init>(Unknown Source)
    > at org.hsqldb.jdbc.jdbcConnection.prepareStatement(Unknown Source)
    > at
    > org.apache.cayenne.conn.ConnectionWrapper.prepareStatement(ConnectionWrapper.java:281)
    > at
    > org.apache.cayenne.conn.ConnectionWrapper.prepareStatement(ConnectionWrapper.java:287)
    > at
    > org.apache.cayenne.access.TransactionConnectionDecorator.prepareStatement(TransactionConnectionDecorator.java:186)
    > at
    > org.apache.cayenne.access.trans.QueryAssembler.createStatement(QueryAssembler.java:196)
    > at
    > org.apache.cayenne.access.jdbc.SelectAction.performAction(SelectAction.java:70)
    > at
    > org.apache.cayenne.access.DataNodeQueryAction.runQuery(DataNodeQueryAction.java:87)
    > at
    > org.apache.cayenne.access.DataNode.performQueries(DataNode.java:274)
    > ... 39 more
    >
    >
    > testSelectCompound2(org.apache.cayenne.access.DataContextFlattenedAttributesTest)
    > Time elapsed: 0.032 sec <<< ERROR!
    > org.apache.cayenne.CayenneRuntimeException: [v.3.0-SNAPSHOT Sep 15
    > 2009 03:01:18] Query exception.
    > at
    > org.apache.cayenne.access.DataDomainQueryAction.nextQueryException(DataDomainQueryAction.java:545)
    > at
    > org.apache.cayenne.access.UnitTestDomainQueryAction.nextQueryException(UnitTestDomainQueryAction.java:36)
    > at
    > org.apache.cayenne.access.DataNode.performQueries(DataNode.java:281)
    > at
    > org.apache.cayenne.access.DataDomainQueryAction.runQuery(DataDomainQueryAction.java:418)
    > at
    > org.apache.cayenne.access.DataDomainQueryAction.access$000(DataDomainQueryAction.java:65)
    > at
    > org.apache.cayenne.access.DataDomainQueryAction$2.transform(DataDomainQueryAction.java:391)
    > at
    > org.apache.cayenne.access.DataDomain.runInTransaction(DataDomain.java:850)
    > at
    > org.apache.cayenne.access.DataDomainQueryAction.runQueryInTransaction(DataDomainQueryAction.java:388)
    > at
    > org.apache.cayenne.access.UnitTestDomainQueryAction.runQueryInTransaction(UnitTestDomainQueryAction.java:54)
    > at
    > org.apache.cayenne.access.DataDomainQueryAction.execute(DataDomainQueryAction.java:117)
    > at
    > org.apache.cayenne.access.UnitTestDomainQueryAction.execute(UnitTestDomainQueryAction.java:48)
    > at
    > org.apache.cayenne.access.UnitTestDomain.onQuery(UnitTestDomain.java:63)
    > at
    > org.apache.cayenne.util.ObjectContextQueryAction.runQuery(ObjectContextQueryAction.java:333)
    > at
    > org.apache.cayenne.util.ObjectContextQueryAction.execute(ObjectContextQueryAction.java:96)
    > at
    > org.apache.cayenne.access.DataContext.onQuery(DataContext.java:1278)
    > at
    > org.apache.cayenne.access.DataContext.performQuery(DataContext.java:1267)
    > at
    > org.apache.cayenne.access.DataContextFlattenedAttributesTest.testSelectCompound2(DataContextFlattenedAttributesTest.java:154)
    > Caused by: java.sql.SQLException: Column not found: T3.PAINTING_ID in
    > statement [SELECT t0.ARTIST_ID, t0.PAINTING_ID, t0.GALLERY_ID,
    > t0.ESTIMATED_PRICE, t1.TEXT_REVIEW, t0.PAINTING_TITLE, t2.ARTIST_NAME,
    > t3.GALLERY_NAME, t3.PAINTING_ID FROM PAINTING t0 JOIN PAINTING_INFO t1
    > ON (t0.PAINTING_ID = t1.PAINTING_ID) JOIN ARTIST t2 ON (t0.ARTIST_ID =
    > t2.ARTIST_ID) JOIN GALLERY t3 ON (t0.GALLERY_ID = t3.GALLERY_ID) WHERE
    > t2.ARTIST_NAME = ?]
    > at org.hsqldb.jdbc.Util.throwError(Unknown Source)
    > at org.hsqldb.jdbc.jdbcPreparedStatement.<init>(Unknown Source)
    > at org.hsqldb.jdbc.jdbcConnection.prepareStatement(Unknown Source)
    > at
    > org.apache.cayenne.conn.ConnectionWrapper.prepareStatement(ConnectionWrapper.java:281)
    > at
    > org.apache.cayenne.conn.ConnectionWrapper.prepareStatement(ConnectionWrapper.java:287)
    > at
    > org.apache.cayenne.access.TransactionConnectionDecorator.prepareStatement(TransactionConnectionDecorator.java:186)
    > at
    > org.apache.cayenne.access.trans.QueryAssembler.createStatement(QueryAssembler.java:196)
    > at
    > org.apache.cayenne.access.jdbc.SelectAction.performAction(SelectAction.java:70)
    > at
    > org.apache.cayenne.access.DataNodeQueryAction.runQuery(DataNodeQueryAction.java:87)
    > at
    > org.apache.cayenne.access.DataNode.performQueries(DataNode.java:274)
    > ... 39 more
    >
    >
    >
    > --
    > Kevin
    >
    >
    >
    > On Mon, Sep 14, 2009 at 9:11 AM, Andrey Razumovsky
    > <razumovsky.andre..mail.com> wrote:
    > > Weird.. Thanks. By the way I stopped getting JPA failures with Maven
    > 2.2.0
    > >
    > > 2009/9/14 Kevin Menard <nirvdru..mail.com>
    > >
    > >> Other than the regular JPA test failures, I had no problems on Windows
    > XP.
    > >>
    > >> --
    > >> Kevin
    > >>
    > >>
    > >>
    > >> On Sat, Sep 12, 2009 at 6:05 PM, Kevin Menard <nirvdru..mail.com>
    > wrote:
    > >> > I'll test on my Windows VM this weekend for you.
    > >> >
    > >> > --
    > >> > Kevin
    > >> >
    > >> >
    > >> >
    > >> > On Thu, Sep 10, 2009 at 9:34 AM, Andrey Razumovsky
    > >> > <razumovsky.andre..mail.com> wrote:
    > >> >> Strange.. could it be it's because I'm on Windows?
    > >> >>
    > >> >> 2009/9/10 Michael Gentry <mgentr..asslight.net>
    > >> >>
    > >> >>> I just did:
    > >> >>>
    > >> >>> svn update; mvn clean; mvn -P mac install
    > >> >>>
    > >> >>> It all built for me.
    > >> >>>
    > >> >>> [INFO] BUILD SUCCESSFUL
    > >> >>> [INFO]
    > >> >>>
    > >> ------------------------------------------------------------------------
    > >> >>> [INFO] Total time: 3 minutes 27 seconds
    > >> >>> [INFO] Finished at: Thu Sep 10 09:20:25 EDT 2009
    > >> >>>
    > >> >>>
    > >> >>> mrg
    > >> >>>
    > >> >>
    > >> >>
    > >> >>
    > >> >> --
    > >> >> Andrey
    > >> >>
    > >> >
    > >>
    > >
    > >
    > >
    > > --
    > > Andrey
    > >
    >

    -- 
    Andrey
    



    This archive was generated by hypermail 2.0.0 : Tue Sep 15 2009 - 12:56:49 EDT