Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions crates/s3/src/admin.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1346,6 +1346,29 @@ mod tests {
handle.join().expect("server thread should finish");
}

#[tokio::test]
async fn test_decommission_start_posts_by_id_multi_pool_query() {
let (endpoint, receiver, handle) = start_admin_test_server("200 OK", "");
let client = admin_client_for_endpoint(&endpoint);

client
.decommission_start(PoolTarget {
pool: "1,2".to_string(),
by_id: true,
})
.await
.expect("decommission start request");

let request = receiver.recv().expect("captured request");
assert_eq!(request.method, "POST");
assert_eq!(
request.target,
"/rustfs/admin/v3/pools/decommission?pool=1%2C2&by-id=true"
);
assert!(request.body.is_empty());
handle.join().expect("server thread should finish");
}

#[tokio::test]
async fn test_decommission_cancel_posts_pool_cancel_route_with_by_id_query() {
let (endpoint, receiver, handle) = start_admin_test_server("200 OK", "");
Expand Down
Loading