From 5981b15902a444c295a980adb726ae94becf1c1d Mon Sep 17 00:00:00 2001 From: "Tobin C. Harding" Date: Tue, 16 Apr 2024 10:03:26 +1000 Subject: [PATCH] kani: Rename tests The tests currently include the word "add" but they test addition as well as subtraction. Elect to keep the multiple assertions per test and just make the names more general. --- units/src/amount.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/units/src/amount.rs b/units/src/amount.rs index 687b569d..cdfbb6b9 100644 --- a/units/src/amount.rs +++ b/units/src/amount.rs @@ -1902,7 +1902,7 @@ mod verification { // CI it fails, so we need to set it higher. #[kani::unwind(4)] #[kani::proof] - fn u_amount_add_homomorphic() { + fn u_amount_homomorphic() { let n1 = kani::any::(); let n2 = kani::any::(); kani::assume(n1.checked_add(n2).is_some()); // assume we don't overflow in the actual test @@ -1932,7 +1932,7 @@ mod verification { #[kani::unwind(4)] #[kani::proof] - fn u_amount_add_homomorphic_checked() { + fn u_amount_homomorphic_checked() { let n1 = kani::any::(); let n2 = kani::any::(); assert_eq!( @@ -1947,7 +1947,7 @@ mod verification { #[kani::unwind(4)] #[kani::proof] - fn s_amount_add_homomorphic() { + fn s_amount_homomorphic() { let n1 = kani::any::(); let n2 = kani::any::(); kani::assume(n1.checked_add(n2).is_some()); // assume we don't overflow in the actual test @@ -1980,7 +1980,7 @@ mod verification { #[kani::unwind(4)] #[kani::proof] - fn s_amount_add_homomorphic_checked() { + fn s_amount_homomorphic_checked() { let n1 = kani::any::(); let n2 = kani::any::(); assert_eq!(