From 1bdb90e56d5e5982ee7fc3e3c72acfab32cdad64 Mon Sep 17 00:00:00 2001 From: Florian Klink Date: Sat, 9 Dec 2023 13:09:58 +0200 Subject: refactor(nix-compat/derivation): address clippy Change-Id: I5d7057347838f733d7dc1331c7b7ef8d27244412 Reviewed-on: https://cl.tvl.fyi/c/depot/+/10228 Tested-by: BuildkiteCI Reviewed-by: tazjin Autosubmit: flokli --- tvix/nix-compat/src/derivation/parser.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'tvix/nix-compat/src/derivation/parser.rs') diff --git a/tvix/nix-compat/src/derivation/parser.rs b/tvix/nix-compat/src/derivation/parser.rs index 36e512514fb6..f54852cb229c 100644 --- a/tvix/nix-compat/src/derivation/parser.rs +++ b/tvix/nix-compat/src/derivation/parser.rs @@ -473,7 +473,7 @@ mod tests { ("out".to_string(), Output { path: "/nix/store/4q0pg5zpfmznxscq3avycvf9xdvx50n3-bar".to_string(), ca_hash: Some(from_algo_and_mode_and_digest("r:sha256", - &data_encoding::HEXLOWER.decode(b"08813cbee9903c62be4c5027726a418a300da4500b2d369d3af9286f4815ceba").unwrap() ).unwrap()), + data_encoding::HEXLOWER.decode(b"08813cbee9903c62be4c5027726a418a300da4500b2d369d3af9286f4815ceba").unwrap() ).unwrap()), }); "fod" )] fn parse_output(input: &[u8], expected: (String, Output)) { @@ -504,7 +504,7 @@ mod tests { #[test] fn from_algo_and_mode_and_digest_failure() { - assert!(from_algo_and_mode_and_digest("r:sha256", &[]).is_err()); - assert!(from_algo_and_mode_and_digest("ha256", &DIGEST_SHA256).is_err()); + assert!(from_algo_and_mode_and_digest("r:sha256", []).is_err()); + assert!(from_algo_and_mode_and_digest("ha256", DIGEST_SHA256).is_err()); } } -- cgit 1.4.1