From 3fc9972c8ed7e385be018c4bb76bb00d61bbd01e Mon Sep 17 00:00:00 2001 From: caglarkaya Date: Sun, 21 Apr 2024 10:18:14 +0300 Subject: [PATCH] fix test case for 0-0 input case in test_and_gate (#119) --- garble/mpz-garble-core/src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/garble/mpz-garble-core/src/lib.rs b/garble/mpz-garble-core/src/lib.rs index 6de97cee..ef7429e2 100644 --- a/garble/mpz-garble-core/src/lib.rs +++ b/garble/mpz-garble-core/src/lib.rs @@ -97,7 +97,7 @@ mod tests { let (z_0, encrypted_gate) = gen::and_gate(cipher, &x_0, &y_0, &delta, gid); let z_1 = z_0 ^ delta; - assert_eq!(ev::and_gate(cipher, &x_0, &y_1, &encrypted_gate, gid), z_0); + assert_eq!(ev::and_gate(cipher, &x_0, &y_0, &encrypted_gate, gid), z_0); assert_eq!(ev::and_gate(cipher, &x_0, &y_1, &encrypted_gate, gid), z_0); assert_eq!(ev::and_gate(cipher, &x_1, &y_0, &encrypted_gate, gid), z_0); assert_eq!(ev::and_gate(cipher, &x_1, &y_1, &encrypted_gate, gid), z_1);