alamb commented on code in PR #7333:
URL: https://github.com/apache/arrow-datafusion/pull/7333#discussion_r1298645402


##########
datafusion/core/src/execution/context.rs:
##########
@@ -2637,42 +2827,6 @@ mod tests {
         Ok(())
     }
 
-    #[tokio::test]

Review Comment:
   I moved this into core_integration as it seemed like a test of the public 
API rather than an internal unit test



##########
datafusion/core/src/execution/context.rs:
##########
@@ -163,35 +167,64 @@ where
 /// * Register a custom data source that can be referenced from a SQL query.
 /// * Execution a SQL query
 ///
+/// # Example: DataFrame API
+///
 /// The following example demonstrates how to use the context to execute a 
query against a CSV
 /// data source using the DataFrame API:
 ///
 /// ```
 /// use datafusion::prelude::*;
-/// # use datafusion::error::Result;
+/// # use datafusion::{error::Result, assert_batches_eq};
 /// # #[tokio::main]
 /// # async fn main() -> Result<()> {
 /// let ctx = SessionContext::new();
 /// let df = ctx.read_csv("tests/data/example.csv", 
CsvReadOptions::new()).await?;
 /// let df = df.filter(col("a").lt_eq(col("b")))?
 ///            .aggregate(vec![col("a")], vec![min(col("b"))])?
 ///            .limit(0, Some(100))?;
-/// let results = df.collect();
+/// let results = df
+///   .collect()
+///   .await?;

Review Comment:
   since the results aren't checked it turns out this code was not actually 
running the plan (missing an `await` so I fixed that)



-- 
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]

Reply via email to