Trunctate the API cleanup branch which was branched off asterix_stabilization. It will be re-created of the asterix_lsm_stabilization branch.

git-svn-id: https://asterixdb.googlecode.com/svn/branches/asterix_lsm_stabilization@1488 eaa15691-b419-025a-1212-ee371bd00084
diff --git a/asterix-app/src/test/java/edu/uci/ics/asterix/test/aql/TestsUtils.java b/asterix-app/src/test/java/edu/uci/ics/asterix/test/aql/TestsUtils.java
index 2602707..7aa04c3 100644
--- a/asterix-app/src/test/java/edu/uci/ics/asterix/test/aql/TestsUtils.java
+++ b/asterix-app/src/test/java/edu/uci/ics/asterix/test/aql/TestsUtils.java
@@ -54,8 +54,12 @@
         try {
 
             while ((lineExpected = readerExpected.readLine()) != null) {
-                if (jArray.length() <= 0) {
-                    throw new Exception("No results returned for query.");
+                // Skipe the blank line in the expected file.
+                if (lineExpected.isEmpty()) {
+                    continue;
+                }
+                if (jArray.length() <= chunkCounter) {
+                    throw new Exception("No more results available.");
                 }
                 JSONArray resultArray = jArray.getJSONArray(chunkCounter);
 
@@ -73,15 +77,8 @@
                 if (recordCounter >= resultArray.length()) {
                     chunkCounter++;
                     recordCounter = 0;
-                    if (chunkCounter >= jArray.length()) {
-                        break;
-                    }
                 }
             }
-
-            while ((lineExpected = readerExpected.readLine()) != null) {
-                // TODO(khurram): Print out the remaining expected file contents
-            }
         } finally {
             readerExpected.close();
         }
diff --git a/asterix-app/src/test/java/edu/uci/ics/asterix/test/runtime/ExecutionTest.java b/asterix-app/src/test/java/edu/uci/ics/asterix/test/runtime/ExecutionTest.java
index aacec61..9a7e1d0 100644
--- a/asterix-app/src/test/java/edu/uci/ics/asterix/test/runtime/ExecutionTest.java
+++ b/asterix-app/src/test/java/edu/uci/ics/asterix/test/runtime/ExecutionTest.java
@@ -233,13 +233,6 @@
         for (CompilationUnit cUnit : cUnits) {
             LOGGER.info("[TEST]: " + tcCtx.getTestCase().getFilePath() + "/" + cUnit.getName());
 
-//            if (!(tcCtx.getTestCase().getFilePath().contains("dml") && cUnit.getName().equals(
-//                    "delete-from-loaded-dataset-with-index"))) {
-//                continue;
-//            }
-//
-//            System.out.println("/Test/: " + tcCtx.getTestCase().getFilePath() + "/" + cUnit.getName());
-
             testFileCtxs = tcCtx.getTestFiles(cUnit);
             expectedResultFileCtxs = tcCtx.getExpectedResultFiles(cUnit);