diff --git a/crates/agones/src/lib.rs b/crates/agones/src/lib.rs index 103b904d4..3d1e26c99 100644 --- a/crates/agones/src/lib.rs +++ b/crates/agones/src/lib.rs @@ -689,7 +689,7 @@ pub fn gameserver_address(gs: &GameServer) -> String { // Useful for determining why something is failing in CI without having to run a cluster. // Requires quilkin::test::enable_log("agones=debug"); to enable debug logging within // the test -pub async fn debug_pods(client: &Client, labels: Option) { +pub async fn debug_pods(client: &Client, labels: String) { debug!(labels, "🪓 Debug output for Selector"); let pods: Api = client.namespaced_api(); let events: Api = client.namespaced_api(); @@ -698,7 +698,7 @@ pub async fn debug_pods(client: &Client, labels: Option) { let event_list = events.list(¶ms).await.unwrap(); let pod_list = pods .list(&ListParams { - label_selector: labels, + label_selector: Some(labels), ..Default::default() }) .await diff --git a/crates/agones/src/provider.rs b/crates/agones/src/provider.rs index b54336983..151f1e24b 100644 --- a/crates/agones/src/provider.rs +++ b/crates/agones/src/provider.rs @@ -109,7 +109,7 @@ mod tests { .await .is_err() { - debug_pods(&client, Some(format!("role={PROXY_DEPLOYMENT}"))).await; + debug_pods(&client, format!("role={PROXY_DEPLOYMENT}")).await; panic!("Quilkin proxy deployment should be ready"); } @@ -157,8 +157,8 @@ mod tests { } } if !failed { - debug_pods(&client, Some(format!("role={PROXY_DEPLOYMENT}"))).await; - debug_pods(&client, Some("role=xds".into())).await; + debug_pods(&client, format!("role={PROXY_DEPLOYMENT}")).await; + debug_pods(&client, "role=xds".into()).await; } assert!(failed, "Packet should have failed"); diff --git a/crates/agones/src/relay.rs b/crates/agones/src/relay.rs index dcea039e0..72025636c 100644 --- a/crates/agones/src/relay.rs +++ b/crates/agones/src/relay.rs @@ -123,7 +123,9 @@ mod tests { .await .is_err() { - debug_pods(&client, None).await; + debug_pods(&client, format!("role={relay_proxy_name}")).await; + debug_pods(&client, "role=xds".into()).await; + debug_pods(&client, "role=agent".into()).await; panic!("Quilkin proxy deployment should be ready"); } @@ -171,7 +173,9 @@ mod tests { } } if !failed { - debug_pods(&client, None).await; + debug_pods(&client, format!("role={relay_proxy_name}")).await; + debug_pods(&client, "role=xds".into()).await; + debug_pods(&client, "role=agent".into()).await; } assert!(failed, "Packet should have failed"); @@ -335,7 +339,7 @@ mod tests { ) .await; if result.is_err() { - debug_pods(client, Some("role=relay".into())).await; + debug_pods(client, "role=relay".into()).await; panic!("Relay Deployment should be ready"); } @@ -392,7 +396,7 @@ mod tests { ) .await; if result.is_err() { - debug_pods(client, Some("role=agent".into())).await; + debug_pods(client, "role=agent".into()).await; panic!("Agent Deployment should be ready"); } result.unwrap().expect("Should have an agent deployment");