From a3fb3902efc3040e3da22262e6eec991bf8e44ed Mon Sep 17 00:00:00 2001 From: Jia-Xuan Liu Date: Sat, 1 Jun 2024 11:57:06 +0800 Subject: [PATCH] fix test --- datafusion/core/src/datasource/file_format/object_storage.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/datafusion/core/src/datasource/file_format/object_storage.rs b/datafusion/core/src/datasource/file_format/object_storage.rs index f2c19bc0583c..8633a779e142 100644 --- a/datafusion/core/src/datasource/file_format/object_storage.rs +++ b/datafusion/core/src/datasource/file_format/object_storage.rs @@ -591,7 +591,8 @@ mod tests { .await .unwrap_err(); - assert_eq!(err.to_string(), "Invalid or Unsupported Configuration: Invalid endpoint: http://endpoint33. HTTP is not allowed for S3 endpoints. To allow HTTP, set 'aws.allow_http' to true"); + // There are other backstraces in the error message, so we just check for containing the message + assert_eq!(err.to_string().contains("Invalid or Unsupported Configuration: Invalid endpoint: http://endpoint33. HTTP is not allowed for S3 endpoints. To allow HTTP, set 'aws.allow_http' to true"), true); } else { return plan_err!("LogicalPlan is not a CreateExternalTable"); }