From 0beaf10ccbebfc5f167430ec4f97fe6f23f1bb27 Mon Sep 17 00:00:00 2001 From: Alex Chi Z Date: Wed, 16 Apr 2025 14:16:43 -0400 Subject: [PATCH] assert download error when key not exist Signed-off-by: Alex Chi Z --- libs/remote_storage/tests/test_real_s3.rs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/libs/remote_storage/tests/test_real_s3.rs b/libs/remote_storage/tests/test_real_s3.rs index 7e1c67f1bf..b85fb82014 100644 --- a/libs/remote_storage/tests/test_real_s3.rs +++ b/libs/remote_storage/tests/test_real_s3.rs @@ -600,6 +600,14 @@ async fn encryption_works(ctx: &mut MaybeEnabledStorage) { assert_eq!(vec.len(), file_len); } + { + let download = ctx + .client + .download(&path, &DownloadOpts::default(), &cancel) + .await; + assert!(download.is_err()); + } + let cancel = CancellationToken::new(); ctx.client.delete_objects(&[path], &cancel).await.unwrap();