You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@poi.apache.org by honyk <j....@email.cz> on 2013/08/25 16:32:17 UTC

POI tests failure

Dear All,

I am writing a test for my POI patch. 

While all changes are built correctly, when I run tests (on HEAD revision),
I am getting many errors:

1. Some of them are caused by missing 'POI.testdata.path' property. How can
I set it properly? When it is set via environment variable, it is ignored.
Changing it directly in build.xml also has no effect.

2. There are other problems in tests themselves (e.g. no test available
etc.). Here is the complete log:


Testcase: warning(junit.framework.TestSuite$1):	FAILED
No tests found in org.apache.poi.hdgf.streams.StreamTest
junit.framework.AssertionFailedError: No tests found in
org.apache.poi.hdgf.streams.StreamTest


Test org.apache.poi.hdgf.streams.StreamTest FAILED
Testsuite: org.apache.poi.hmef.HMEFTest
Tests run: 1, Failures: 0, Errors: 1, Time elapsed: 0 sec

Null Test: 	Caused an ERROR
null
java.lang.ExceptionInInitializerError
	at java.lang.Class.forName0(Native Method)
	at java.lang.Class.forName(Class.java:186)
Caused by: java.lang.RuntimeException: Must set system property
'POI.testdata.path' before running tests
	at org.apache.poi.POIDataSamples.initialise(POIDataSamples.java:193)
	at org.apache.poi.POIDataSamples.<init>(POIDataSamples.java:60)
	at
org.apache.poi.POIDataSamples.getHMEFInstance(POIDataSamples.java:109)
	at org.apache.poi.hmef.HMEFTest.<clinit>(HMEFTest.java:28)


Test org.apache.poi.hmef.HMEFTest FAILED
Testsuite: org.apache.poi.hwpf.converter.AbstractWordUtilsTest
Tests run: 1, Failures: 0, Errors: 1, Time elapsed: 0,1 sec

Testcase:
testBuildTableCellEdgesArray(org.apache.poi.hwpf.converter.AbstractWordUtils
Test):	Caused an ERROR
Must set system property 'POI.testdata.path' before running tests
java.lang.RuntimeException: Must set system property 'POI.testdata.path'
before running tests
	at org.apache.poi.POIDataSamples.initialise(POIDataSamples.java:193)
	at org.apache.poi.POIDataSamples.<init>(POIDataSamples.java:60)
	at
org.apache.poi.POIDataSamples.getDocumentInstance(POIDataSamples.java:69)
	at
org.apache.poi.hwpf.HWPFTestDataSamples.openSampleFile(HWPFTestDataSamples.j
ava:39)
	at
org.apache.poi.hwpf.converter.AbstractWordUtilsTest.testBuildTableCellEdgesA
rray(AbstractWordUtilsTest.java:38)


Test org.apache.poi.hwpf.converter.AbstractWordUtilsTest FAILED
Testsuite: org.apache.poi.hwpf.model.types.LFOLVLBaseAbstractTypeTest
Tests run: 1, Failures: 0, Errors: 0, Time elapsed: 0,08 sec

Testsuite: org.apache.poi.hwpf.model.types.LVLFAbstractTypeTest
Tests run: 1, Failures: 0, Errors: 0, Time elapsed: 0,08 sec

Testsuite: org.apache.poi.hwpf.sprm.TableSprmUncompressorTest
Tests run: 1, Failures: 0, Errors: 0, Time elapsed: 0,1 sec

Testsuite: org.apache.poi.ss.excelant.BuildFileTest
Tests run: 1, Failures: 1, Errors: 0, Time elapsed: 0,08 sec

Testcase: warning(junit.framework.TestSuite$1):	FAILED
No tests found in org.apache.poi.ss.excelant.BuildFileTest
junit.framework.AssertionFailedError: No tests found in
org.apache.poi.ss.excelant.BuildFileTest

Test org.apache.poi.ss.excelant.BuildFileTest FAILED


Any idea?

Thanks, Jan



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


RE: POI tests failure

Posted by honyk <j....@email.cz>.
On 2013-08-25 Nick Burch wrote:
> On Sun, 25 Aug 2013, honyk wrote:
> > While all changes are built correctly, when I run tests (on HEAD
> > revision), I am getting many errors:
> 
> How are you running the tests? "ant test" or something else (eg in
> eclipse?)

Directly from Netbeans IDE
 
> > 1. Some of them are caused by missing 'POI.testdata.path' property.
> How can
> > I set it properly? When it is set via environment variable, it is
> ignored.
> > Changing it directly in build.xml also has no effect.
> 
> It needs to point to where the test files are. If running "ant test" it
> should be there. If running in eclipse, you'll need to set it as a run
> variable

Calling ant directly via cmdline does the job (seamlessly), thanks for the
hint!

Jan


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


Re: POI tests failure

Posted by Nick Burch <ap...@gagravarr.org>.
On Sun, 25 Aug 2013, honyk wrote:
> While all changes are built correctly, when I run tests (on HEAD 
> revision), I am getting many errors:

How are you running the tests? "ant test" or something else (eg in 
eclipse?)

> 1. Some of them are caused by missing 'POI.testdata.path' property. How can
> I set it properly? When it is set via environment variable, it is ignored.
> Changing it directly in build.xml also has no effect.

It needs to point to where the test files are. If running "ant test" it 
should be there. If running in eclipse, you'll need to set it as a run 
variable

Nick

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org