From 27790aa67c90b9ae0e31c45670af172fc9266ee4 Mon Sep 17 00:00:00 2001 From: Fabian-Lars Date: Tue, 11 Nov 2025 22:56:09 +0100 Subject: [PATCH] chore: fix upload test on macos ci (#3097) --- plugins/upload/src/lib.rs | 4 ++-- plugins/upload/test/{test.txt => download.txt} | 0 plugins/upload/test/upload.txt | 1 + 3 files changed, 3 insertions(+), 2 deletions(-) rename plugins/upload/test/{test.txt => download.txt} (100%) create mode 100644 plugins/upload/test/upload.txt diff --git a/plugins/upload/src/lib.rs b/plugins/upload/src/lib.rs index 224375dff..1f39786f5 100644 --- a/plugins/upload/src/lib.rs +++ b/plugins/upload/src/lib.rs @@ -298,7 +298,7 @@ mod tests { } async fn download_file(url: String) -> Result<()> { - let file_path = concat!(env!("CARGO_MANIFEST_DIR"), "/test/test.txt").to_string(); + let file_path = concat!(env!("CARGO_MANIFEST_DIR"), "/test/download.txt").to_string(); let headers = HashMap::new(); let sender: Channel = Channel::new(|msg: InvokeResponseBody| -> tauri::Result<()> { @@ -309,7 +309,7 @@ mod tests { } async fn upload_file(url: String, method: Option) -> Result { - let file_path = concat!(env!("CARGO_MANIFEST_DIR"), "/test/test.txt").to_string(); + let file_path = concat!(env!("CARGO_MANIFEST_DIR"), "/test/upload.txt").to_string(); let headers = HashMap::new(); let sender: Channel = Channel::new(|msg: InvokeResponseBody| -> tauri::Result<()> { diff --git a/plugins/upload/test/test.txt b/plugins/upload/test/download.txt similarity index 100% rename from plugins/upload/test/test.txt rename to plugins/upload/test/download.txt diff --git a/plugins/upload/test/upload.txt b/plugins/upload/test/upload.txt new file mode 100644 index 000000000..629b997b3 --- /dev/null +++ b/plugins/upload/test/upload.txt @@ -0,0 +1 @@ +mocked response body \ No newline at end of file