From 34dabcbed7b1d34f952534d87c0df3b3ff0f0856 Mon Sep 17 00:00:00 2001 From: David Peter Date: Sun, 6 Feb 2022 17:23:43 +0100 Subject: [PATCH] Integration test for duplicate parameter names --- tests/integration_tests.rs | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/tests/integration_tests.rs b/tests/integration_tests.rs index 1e235b0..f0418ca 100644 --- a/tests/integration_tests.rs +++ b/tests/integration_tests.rs @@ -56,6 +56,21 @@ fn fails_with_wrong_number_of_prepare_options() { )); } +#[test] +fn fails_with_duplicate_parameter_names() { + hyperfine() + .arg("--parameter-list") + .arg("x") + .arg("1,2,3") + .arg("--parameter-list") + .arg("x") + .arg("a,b,c") + .arg("echo test") + .assert() + .failure() + .stderr(predicate::str::contains("Duplicate parameter names: x")); +} + #[test] fn fails_for_unknown_command() { hyperfine()