feat: add a test macro (#170)

This commit is contained in:
Tobias Pütz
2025-06-23 13:38:40 +02:00
committed by GitHub
parent 720943b4bb
commit 8497fdb4ba
42 changed files with 665 additions and 464 deletions

View File

@@ -19,11 +19,8 @@ use minio::s3::response::{BucketExistsResponse, DeleteBucketResponse};
use minio::s3::types::S3Api;
use minio_common::test_context::TestContext;
#[tokio::test(flavor = "multi_thread")]
async fn bucket_exists() {
let ctx = TestContext::new_from_env();
let (bucket_name, _cleanup) = ctx.create_bucket_helper().await;
#[minio_macros::test(no_cleanup)]
async fn bucket_exists(ctx: TestContext, bucket_name: String) {
let resp: BucketExistsResponse = ctx.client.bucket_exists(&bucket_name).send().await.unwrap();
assert!(resp.exists());
assert_eq!(resp.bucket(), bucket_name);