Unable to run tests with ivy/help with maven2

14 views
Skip to first unread message

Todd

unread,
Nov 13, 2010, 4:51:08 PM11/13/10
to lucandra-user
Hey Jake,
I'm adding a maven build process to my fork of your solandra code.
At the moment, the ivy test target doesn't work for me. I receive the
error

compile.tests:
[javac] /Users/toddnine/development/lucandra/build.xml:137:
warning: 'includeantruntime' was not set, defaulting to
build.sysclasspath=last; set to false for repeatable builds

test:
[echo] running tests
[junit] WARNING: multiple versions of ant detected in path for
junit
[junit] jar:file:/usr/share/ant/lib/ant.jar!/org/apache/
tools/ant/Project.class
[junit] and jar:file:/Users/toddnine/development/lucandra/lib/
ant-1.6.5.jar!/org/apache/tools/ant/Project.class
[junit] Testsuite: solandra.SolandraTests$1
[junit] Tests run: 2, Failures: 0, Errors: 2, Time elapsed: 0.067
sec
[junit]
[junit] Testcase: initializationError(solandra.SolandraTests$1):
Caused an ERROR
[junit] Test class should have exactly one public constructor
[junit] java.lang.Exception: Test class should have exactly one
public constructor
[junit] at
java.lang.reflect.Constructor.newInstance(Constructor.java:513)
[junit]
[junit]
[junit] Testcase: initializationError(solandra.SolandraTests$1):
Caused an ERROR
[junit] No runnable methods
[junit] java.lang.Exception: No runnable methods
[junit] at
java.lang.reflect.Constructor.newInstance(Constructor.java:513)
[junit]
[junit]
[junit] Test solandra.SolandraTests$1 FAILED
[junit] Testsuite: solandra.SolandraTests
[junit] Testsuite: solandra.SolandraTests
[junit] Tests run: 1, Failures: 0, Errors: 1, Time elapsed: 0 sec
[junit]
[junit] Testcase: solandra.SolandraTests:BeforeFirstTest: Caused
an ERROR
[junit] Forked Java VM exited abnormally. Please note the time in
the report does not reflect the time until the VM exit.
[junit] junit.framework.AssertionFailedError: Forked Java VM
exited abnormally. Please note the time in the report does not reflect
the time until the VM exit.
[junit]
[junit]
[junit] Test solandra.SolandraTests FAILED (crashed)


Also, when I'm setting up my maven build, I have the following JVM
args(which match the ant build).

-Xmx1G -Dsolr.solr.home=resources

I always receive the error

can't find resource 'solrconfig.xml' in classpath or 'solr/conf/',
cwd=/Users/toddnine/development/lucandra

Does version c9d9dad17cd65b3120af8fb3506fbe159fd83c64 pass the tests
when running "ant test" for you?

Jake Luciani

unread,
Nov 13, 2010, 6:21:39 PM11/13/10
to lucand...@googlegroups.com
Ah. I probably need to update this. Thx.

Jake Luciani

unread,
Nov 13, 2010, 8:16:01 PM11/13/10
to lucand...@googlegroups.com
Fixed.

Todd

unread,
Nov 14, 2010, 11:45:59 PM11/14/10
to lucandra-user
Hi Jake,
It appears the tests are broken. I just merged in your fork, the
only thing I've added is a pom.xml, which isn't functional to match
the ant task yet. I receive error this with every test case. Is
there some initialization that I need to perform before running the
"ant test" target?

[junit] 17:37:21,225 INFO SolandraCoreContainer:72 - Loading Solandra
core:
[junit] 17:37:21,236 ERROR SolrCore:139 -
java.lang.NullPointerException
[junit] at org.apache.cassandra.db.Table.<init>(Table.java:241)
[junit] at org.apache.cassandra.db.Table.open(Table.java:113)
[junit] at
org.apache.cassandra.service.StorageService.getNaturalEndpoints(StorageService.java:
1414)
[junit] at
org.apache.cassandra.service.StorageService.getNaturalEndpoints(StorageService.java:
1402)
[junit] at
org.apache.cassandra.service.StorageService.findSuitableEndpoint(StorageService.java:
1448)
[junit] at
org.apache.cassandra.service.StorageProxy.weakRead(StorageProxy.java:
244)
[junit] at
org.apache.cassandra.service.StorageProxy.readProtocol(StorageProxy.java:
223)
[junit] at lucandra.CassandraUtils.robustRead(CassandraUtils.java:
390)
[junit] at
lucandra.LucandraTermEnum.loadTerms(LucandraTermEnum.java:255)
[junit] at lucandra.LucandraTermEnum.skipTo(LucandraTermEnum.java:
83)
[junit] at lucandra.IndexReader.docFreq(IndexReader.java:166)
[junit] at
org.apache.solr.search.SolrIndexReader.docFreq(SolrIndexReader.java:
308)
[junit] at
org.apache.lucene.search.IndexSearcher.docFreq(IndexSearcher.java:147)
[junit] at
org.apache.lucene.search.Similarity.idfExplain(Similarity.java:765)
[junit] at org.apache.lucene.search.TermQuery
$TermWeight.<init>(TermQuery.java:46)
[junit] at
org.apache.lucene.search.TermQuery.createWeight(TermQuery.java:146)
[junit] at org.apache.lucene.search.Query.weight(Query.java:99)
[junit] at
org.apache.lucene.search.Searcher.createWeight(Searcher.java:230)
[junit] at org.apache.lucene.search.Searcher.search(Searcher.java:
171)
[junit] at
org.apache.solr.search.SolrIndexSearcher.getDocListNC(SolrIndexSearcher.java:
988)
[junit] at
org.apache.solr.search.SolrIndexSearcher.getDocListC(SolrIndexSearcher.java:
884)
[junit] at
org.apache.solr.search.SolrIndexSearcher.search(SolrIndexSearcher.java:
341)
[junit] at
org.apache.solr.handler.component.QueryComponent.process(QueryComponent.java:
182)
[junit] at
org.apache.solr.handler.component.SearchHandler.handleRequestBody(SearchHandler.java:
195)
[junit] at
org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:
131)
[junit] at org.apache.solr.core.SolrCore.execute(SolrCore.java:
1316)
[junit] at
org.apache.solr.servlet.SolrDispatchFilter.execute(SolrDispatchFilter.java:
338)
[junit] at
solandra.SolandraDispatchFilter.execute(SolandraDispatchFilter.java:
169)
[junit] at
org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:
241)
[junit] at
solandra.SolandraDispatchFilter.doFilter(SolandraDispatchFilter.java:
133)
[junit] at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1084)
[junit] at
org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:
360)
[junit] at
org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:
181)
[junit] at
org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:
722)
[junit] at
org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:
139)
[junit] at org.mortbay.jetty.Server.handle(Server.java:324)
[junit] at
org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:
505)
[junit] at org.mortbay.jetty.HttpConnection
$RequestHandler.headerComplete(HttpConnection.java:828)
[junit] at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:
514)
[junit] at
org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:211)
[junit] at
org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:380)
[junit] at org.mortbay.jetty.bio.SocketConnector
$Connection.run(SocketConnector.java:228)
[junit] at org.mortbay.thread.BoundedThreadPool
$PoolThread.run(BoundedThreadPool.java:450)




On Nov 14, 2:16 pm, Jake Luciani <jak...@gmail.com> wrote:
> Fixed.
>
> On Sat, Nov 13, 2010 at 6:21 PM, Jake Luciani <jak...@gmail.com> wrote:
> > Ah. I probably need to update this. Thx.
>

Jake Luciani

unread,
Nov 15, 2010, 8:46:10 AM11/15/10
to lucand...@googlegroups.com
You need to make sure resources and resources/solr are in the classpath.
Reply all
Reply to author
Forward
0 new messages