From f7df6771aa6da2bd04e6e0bb21bde6076c6f2409 Mon Sep 17 00:00:00 2001 From: gwest Date: Mon, 18 May 2026 09:08:02 -0500 Subject: [PATCH 1/2] fix(tests): commissioning + mdns helper compile against current API The 'commissioning' integration test fails to build on main with three errors when the astro-dnssd feature is selected: 1. rs-matter/tests/common/mdns.rs: AstroMdnsResponder constructor changed from new(matter) -> new() with matter passed to run(matter). The test helper still calls the old shape. 2. rs-matter/tests/commissioning.rs: the test's local discover_device helper still takes a u16 discriminator, but its caller now passes a &CommissionableFilter (matching the zbus/zeroconf variant). The astro-dnssd variant also internally constructs a filter from just the discriminator, dropping any other filter fields the caller specified. Repro on main (verified): cargo test -p rs-matter --test commissioning \ --no-default-features \ --features 'std,rustcrypto,log,astro-dnssd' --no-run error[E0308]: mismatched types ... expected u16, found &CommissionableFilter error[E0061]: this method takes 1 argument but 0 were supplied (AstroMdnsResponder::run) Fix --- - mdns.rs: use the current AstroMdnsResponder::new().run(matter) shape. - commissioning.rs: unify discover_device(...) across feature variants to take &CommissionableFilter directly, so the caller's full filter passes through and both branches have the same signature. After this patch the test builds clean under astro-dnssd. --- rs-matter/tests/commissioning.rs | 17 ++++++++++------- rs-matter/tests/common/mdns.rs | 4 ++-- 2 files changed, 12 insertions(+), 9 deletions(-) diff --git a/rs-matter/tests/commissioning.rs b/rs-matter/tests/commissioning.rs index 61239781..73aad8fb 100644 --- a/rs-matter/tests/commissioning.rs +++ b/rs-matter/tests/commissioning.rs @@ -338,18 +338,18 @@ async fn discover_and_resolve_device(timeout_ms: u32, use_tcp: bool) -> Result( - discriminator: u16, + filter: &CommissionableFilter, timeout_ms: u32, ) -> Result, Error> { use rs_matter::transport::network::mdns::astro; + let filter_owned = filter.clone(); let (tx, rx) = async_channel::bounded(1); std::thread::spawn(move || { - let filter = CommissionableFilter { - discriminator: Some(discriminator), - ..Default::default() - }; - let _ = tx.send_blocking(astro::discover_commissionable::(&filter, timeout_ms)); + let _ = tx.send_blocking(astro::discover_commissionable::( + &filter_owned, + timeout_ms, + )); }); let devices = rx @@ -358,7 +358,10 @@ async fn discover_device( .map_err(|_| Error::from(rs_matter::error::ErrorCode::Failure))??; devices.into_iter().next().ok_or_else(|| { - warn!("No devices found matching discriminator {discriminator}"); + warn!( + "No devices found matching discriminator {:?}", + filter.discriminator + ); rs_matter::error::ErrorCode::NotFound.into() }) } diff --git a/rs-matter/tests/common/mdns.rs b/rs-matter/tests/common/mdns.rs index f46d4cf7..0e669896 100644 --- a/rs-matter/tests/common/mdns.rs +++ b/rs-matter/tests/common/mdns.rs @@ -32,8 +32,8 @@ use rs_matter::{crypto::Crypto, error::Error}; #[allow(unused)] pub async fn run_mdns(matter: &Matter<'_>, crypto: C) -> Result<(), Error> { #[cfg(feature = "astro-dnssd")] - rs_matter::transport::network::mdns::astro::AstroMdnsResponder::new(matter) - .run() + rs_matter::transport::network::mdns::astro::AstroMdnsResponder::new() + .run(matter) .await?; #[cfg(all(feature = "zeroconf", not(feature = "astro-dnssd")))] From 86dc302a5c2355004505dab749d308e32d787024 Mon Sep 17 00:00:00 2001 From: gwest Date: Mon, 18 May 2026 11:03:14 -0500 Subject: [PATCH 2/2] ci: empty commit to retry flaky openssl test_root_cert_consistent