()
| 225 | use datafusion::prelude::SessionContext; |
| 226 | |
| 227 | fn setup_context() -> (SessionContext, Arc<dyn SchemaProvider>) { |
| 228 | let ctx = SessionContext::new(); |
| 229 | ctx.register_catalog_list(Arc::new(DynamicObjectStoreCatalog::new( |
| 230 | ctx.state().catalog_list().clone(), |
| 231 | ctx.state_weak_ref(), |
| 232 | ))); |
| 233 | |
| 234 | let provider = &DynamicObjectStoreCatalog::new( |
| 235 | ctx.state().catalog_list().clone(), |
| 236 | ctx.state_weak_ref(), |
| 237 | ) as &dyn CatalogProviderList; |
| 238 | let catalog = provider |
| 239 | .catalog(provider.catalog_names().first().unwrap()) |
| 240 | .unwrap(); |
| 241 | let schema = catalog |
| 242 | .schema(catalog.schema_names().first().unwrap()) |
| 243 | .unwrap(); |
| 244 | (ctx, schema) |
| 245 | } |
| 246 | |
| 247 | #[tokio::test] |
| 248 | async fn query_http_location_test() -> Result<()> { |
no test coverage detected
searching dependent graphs…