rdf4j: ElasticSearchIndexTest failing

The ElasticSearchIndexTest is failing for me (as it is for Hudson) in two places with the following messages:

Running org.eclipse.rdf4j.sail.elasticsearch.ElasticsearchIndexTest
Tests run: 5, Failures: 2, Errors: 0, Skipped: 0, Time elapsed: 1.453 sec <<< FAILURE! - in org.eclipse.rdf4j.sail.elasticsearch.ElasticsearchIndexTest
testAddStatement(org.eclipse.rdf4j.sail.elasticsearch.ElasticsearchIndexTest)  Time elapsed: 0.287 sec  <<< FAILURE!
java.lang.AssertionError: expected:<1> but was:<6>
	at org.junit.Assert.fail(Assert.java:88)
	at org.junit.Assert.failNotEquals(Assert.java:834)
	at org.junit.Assert.assertEquals(Assert.java:645)
	at org.junit.Assert.assertEquals(Assert.java:631)
	at org.eclipse.rdf4j.sail.elasticsearch.ElasticsearchIndexTest.testAddStatement(ElasticsearchIndexTest.java:141)

testAddMultiple(org.eclipse.rdf4j.sail.elasticsearch.ElasticsearchIndexTest)  Time elapsed: 0.28 sec  <<< FAILURE!
java.lang.AssertionError: expected:<2> but was:<7>
	at org.junit.Assert.fail(Assert.java:88)
	at org.junit.Assert.failNotEquals(Assert.java:834)
	at org.junit.Assert.assertEquals(Assert.java:645)
	at org.junit.Assert.assertEquals(Assert.java:631)
	at org.eclipse.rdf4j.sail.elasticsearch.ElasticsearchIndexTest.testAddMultiple(ElasticsearchIndexTest.java:248)


Results :

Failed tests: 
  ElasticsearchIndexTest.testAddStatement:141 expected:<1> but was:<6>
  ElasticsearchIndexTest.testAddMultiple:248 expected:<2> but was:<7>

About this issue

  • Original URL
  • State: closed
  • Created 8 years ago
  • Comments: 15 (12 by maintainers)

Commits related to this issue

Most upvoted comments

I think this was fixed in #700 as I haven’t seen it since then.

ElasticsearchIndexTest should not be using a single directory for all of its operations “target/test-data”, it should be using a JUnit TemporaryFolder Rule. Also the tearDown method in ElasticsearchIndexTest could be improved by using try-finally to reset more thoroughly after that to make sure there are no locks on files inside of the JUnit TemporaryFolder.

Huh? is this a glitch in GitHub? I’m pretty sure that I didn’t send the above mail message…