diff --git a/primitives/src/communities.rs b/primitives/src/communities.rs index 936a5a5e..058b27f5 100644 --- a/primitives/src/communities.rs +++ b/primitives/src/communities.rs @@ -424,8 +424,8 @@ mod tests { Degree, Demurrage, Location, PalletString, RangeError, }, }; + use frame_support::assert_err; use sp_std::str::FromStr; - use std::assert_matches::assert_matches; #[test] fn demurrage_smaller_0_fails() { @@ -509,8 +509,8 @@ mod tests { #[test] fn invalid_cid_from_str_errs() { - assert_matches!( - CommunityIdentifier::from_str("gbsuv7YXq9l").unwrap_err(), + assert_err!( + CommunityIdentifier::from_str("gbsuv7YXq9l"), bs58::decode::Error::InvalidCharacter { character: 'l', index: 10 } ) } diff --git a/primitives/src/lib.rs b/primitives/src/lib.rs index 6984cf25..687c38c9 100644 --- a/primitives/src/lib.rs +++ b/primitives/src/lib.rs @@ -15,7 +15,6 @@ // along with Encointer. If not, see . #![cfg_attr(not(feature = "std"), no_std)] -#![cfg_attr(test, feature(assert_matches))] pub mod balances; pub mod bazaar;