You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@asterixdb.apache.org by "Ian Maxon (JIRA)" <ji...@apache.org> on 2016/01/15 17:44:39 UTC
[jira] [Resolved] (ASTERIXDB-1200)
AbstractIntegrationTest#runTestAndCompareResults fails when the output file
is empty
[ https://issues.apache.org/jira/browse/ASTERIXDB-1200?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Ian Maxon resolved ASTERIXDB-1200.
----------------------------------
Resolution: Fixed
> AbstractIntegrationTest#runTestAndCompareResults fails when the output file is empty
> ------------------------------------------------------------------------------------
>
> Key: ASTERIXDB-1200
> URL: https://issues.apache.org/jira/browse/ASTERIXDB-1200
> Project: Apache AsterixDB
> Issue Type: Bug
> Components: Test Framework
> Environment: Ubuntu 15.04
> Eclipse
> Oracle JDK 8
> Reporter: Ahmed Eldawy
> Assignee: Ian Maxon
> Priority: Minor
> Labels: test
> Original Estimate: 2h
> Remaining Estimate: 2h
>
> I have a test case which has five tuples in the expected answer. If the actual resul file is empty, I expect the test to fail with an assertion failure. However, it fails with the following ArrayIndexOutOfBoundsException.
> java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
> at java.util.ArrayList.rangeCheck(ArrayList.java:653)
> at java.util.ArrayList.get(ArrayList.java:429)
> at org.apache.hyracks.tests.integration.AbstractIntegrationTest.runTestAndCompareResults(AbstractIntegrationTest.java:196)
> ....
> I tried to modify the condition
> while ((expectedLine = expectedFile.readLine()) != null)
> to
> while (j < results.size() && (expectedLine = expectedFile.readLine()) != null)
> but the test passed with no failures.
> Although, in my case, the test does not pass, it fails with an exception instead of an assertion error.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)