From 57f02a1587555176f1b43b001e7846ac9eb2e949 Mon Sep 17 00:00:00 2001 From: Sven-Hendrik Haase Date: Thu, 6 Feb 2025 05:18:20 +0100 Subject: Clean up and modernize rstest usage We still had some old-style syntax in there. --- tests/header.rs | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'tests/header.rs') diff --git a/tests/header.rs b/tests/header.rs index ea4c462..443f2ba 100644 --- a/tests/header.rs +++ b/tests/header.rs @@ -4,11 +4,10 @@ mod fixtures; use crate::fixtures::{server, Error}; -#[rstest(headers, - case(vec!["x-info: 123".to_string()]), - case(vec!["x-info1: 123".to_string(), "x-info2: 345".to_string()]) -)] -fn custom_header_set(headers: Vec) -> Result<(), Error> { +#[rstest] +#[case(vec!["x-info: 123".to_string()])] +#[case(vec!["x-info1: 123".to_string(), "x-info2: 345".to_string()])] +fn custom_header_set(#[case] headers: Vec) -> Result<(), Error> { let server = server(headers.iter().flat_map(|h| vec!["--header", h])); let resp = reqwest::blocking::get(server.url())?; -- cgit v1.2.3