Skip to content

Commit 9be3575

Browse files
committed
split tests into new_pass_test and new_fail_test
This uses the tool described in RustCrypto/traits#2019 and this script: ``` find -name '*.blb' ! -path "./mgm/tests/data/*" -exec ./split-blobby {} \; -delete ``` and a sed script to split most of the tests: ``` for p in $(rg -l aead::new_test); do sed -i '/aead::new_test!/ { h; s/new_test!/new_pass_test!/; s/,/_pass,/; s/",/_pass",/; p; g; s/new_test!/new_fail_test!/; s/,/_fail,/; s/",/_fail",/ }' $p; done ```
1 parent b396ec4 commit 9be3575

File tree

177 files changed

+158
-71
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

177 files changed

+158
-71
lines changed

Cargo.lock

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,5 +19,6 @@ members = [
1919
aead-stream = { path = "aead-stream" }
2020
aes-gcm = { path = "aes-gcm" }
2121

22+
# https://github.com/RustCrypto/traits/pull/2019
2223
aead = { git = "https://github.com/RustCrypto/traits.git" }
2324
crypto-common = { git = "https://github.com/RustCrypto/traits.git" }

aes-gcm-siv/tests/aes128gcmsiv.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,4 +185,5 @@ const TEST_VECTORS: &[TestVector<[u8; 16]>] = &[
185185
tests!(Aes128GcmSiv, TEST_VECTORS);
186186

187187
// Test vectors from Wycheproof
188-
aead::new_test!(wycheproof, "wycheproof-128", Aes128GcmSiv);
188+
aead::new_pass_test!(wycheproof_pass, "wycheproof-128_pass", Aes128GcmSiv);
189+
aead::new_fail_test!(wycheproof_fail, "wycheproof-128_fail", Aes128GcmSiv);

aes-gcm-siv/tests/aes256gcmsiv.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,4 +185,5 @@ const TEST_VECTORS: &[TestVector<[u8; 32]>] = &[
185185
tests!(Aes256GcmSiv, TEST_VECTORS);
186186

187187
// Test vectors from Wycheproof
188-
aead::new_test!(wycheproof, "wycheproof-256", Aes256GcmSiv);
188+
aead::new_pass_test!(wycheproof_pass, "wycheproof-256_pass", Aes256GcmSiv);
189+
aead::new_fail_test!(wycheproof_fail, "wycheproof-256_fail", Aes256GcmSiv);
-4.6 KB
Binary file not shown.
840 Bytes
Binary file not shown.
3.74 KB
Binary file not shown.
-5.25 KB
Binary file not shown.
919 Bytes
Binary file not shown.
4.29 KB
Binary file not shown.

0 commit comments

Comments
 (0)