berkaysynnada commented on code in PR #15905:
URL: https://github.com/apache/datafusion/pull/15905#discussion_r2070694736


##########
datafusion/sqllogictest/bin/sqllogictests.rs:
##########
@@ -235,14 +235,38 @@ async fn run_test_file(
     runner.with_normalizer(value_normalizer);
     runner.with_validator(validator);
 
-    let res = runner
-        .run_file_async(path)
-        .await
-        .map_err(|e| DataFusionError::External(Box::new(e)));
+    let path = path.canonicalize()?;
+    let records =
+        parse_file(&path).map_err(|e| DataFusionError::External(Box::new(e)))?;
+    let mut errs = vec![];
+    for record in records.into_iter() {
+        if let Record::Halt { .. } = record {
+            break;
+        }
+        if let Err(err) = runner.run_async(record).await {
+            errs.push(format!("{err}"));
+        }
+    }
 
     pb.finish_and_clear();
 
-    res
+    if errs.is_empty() {
+        return Ok(());
+    }
+    const ERR_LIMIT: usize = 10;

Review Comment:
   Better to define at the top where other constant are defined ?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to