test: update to use fmtlib specifiers
This commit is contained in:
parent
9428d5ee60
commit
220072fd6d
@ -53,8 +53,8 @@ main ()
|
||||
std::array<uint32_t,2> dec;
|
||||
gen.decrypt (cruft::view (dec), cruft::view (t.enc));
|
||||
|
||||
tap.expect (enc == t.enc, "TEA_enc %zu", i);
|
||||
tap.expect (dec == t.dec, "TEA_dec %zu", i);
|
||||
tap.expect (enc == t.enc, "TEA_enc {}", i);
|
||||
tap.expect (dec == t.dec, "TEA_dec {}", i);
|
||||
}
|
||||
|
||||
return tap.status ();
|
||||
|
@ -51,8 +51,8 @@ main ()
|
||||
std::array<uint32_t,2> dec_result;
|
||||
gen.decrypt (cruft::view (dec_result), cruft::view (enc_result));
|
||||
|
||||
tap.expect (enc_result == t.enc, "XTEA_enc %zu", i);
|
||||
tap.expect (dec_result == t.dec, "XTEA_dec %zu", i);
|
||||
tap.expect (enc_result == t.enc, "XTEA_enc {}", i);
|
||||
tap.expect (dec_result == t.dec, "XTEA_dec {}", i);
|
||||
}
|
||||
|
||||
return tap.status ();
|
||||
|
@ -109,8 +109,8 @@ main ()
|
||||
std::vector<uint32_t> dec_result (t.enc.size ());
|
||||
gen.decrypt (cruft::view (dec_result), cruft::view (t.enc));
|
||||
|
||||
tap.expect (enc_result == t.enc, "XXTEA_enc %zu", i);
|
||||
tap.expect (dec_result == t.dec, "XXTEA_dec %zu", i);
|
||||
tap.expect (enc_result == t.enc, "XXTEA_enc {}", i);
|
||||
tap.expect (dec_result == t.dec, "XXTEA_dec {}", i);
|
||||
}
|
||||
|
||||
return tap.status ();
|
||||
|
@ -278,7 +278,7 @@ main (int, char**)
|
||||
cruft::TAP::logger tap;
|
||||
|
||||
for (size_t i = 0; i < std::size (TESTS); ++i)
|
||||
tap.expect (TESTS[i].fun (TESTS[i].key, TESTS[i].dat, TESTS[i].res), "standard test vector %zu", i);
|
||||
tap.expect (TESTS[i].fun (TESTS[i].key, TESTS[i].dat, TESTS[i].res), "standard test vector {}", i);
|
||||
|
||||
return tap.status ();
|
||||
}
|
||||
|
@ -390,7 +390,7 @@ main ()
|
||||
success = success && std::equal (std::begin (data), std::end (data), std::begin (t.data[j]));
|
||||
};
|
||||
|
||||
tap.expect (success, "ARC4 %zu", i);
|
||||
tap.expect (success, "ARC4 {}", i);
|
||||
}
|
||||
|
||||
return tap.status ();
|
||||
|
@ -30,7 +30,7 @@ test_quarter (cruft::TAP::logger &tap)
|
||||
tap.expect_eq (
|
||||
cruft::crypto::stream::salsa::quarter (TESTS[i].a),
|
||||
TESTS[i].b,
|
||||
"quarter %zu", i
|
||||
"quarter {}", i
|
||||
);
|
||||
}
|
||||
|
||||
@ -66,7 +66,7 @@ test_row (cruft::TAP::logger &tap)
|
||||
tap.expect_eq (
|
||||
cruft::crypto::stream::salsa::row (TESTS[i].a),
|
||||
TESTS[i].b,
|
||||
"row %zu",
|
||||
"row {}",
|
||||
i);
|
||||
}
|
||||
|
||||
@ -100,7 +100,7 @@ test_col (cruft::TAP::logger &tap)
|
||||
tap.expect_eq (
|
||||
cruft::crypto::stream::salsa::col (TESTS[i].a),
|
||||
TESTS[i].b,
|
||||
"col %zu",
|
||||
"col {}",
|
||||
i);
|
||||
}
|
||||
|
||||
@ -134,7 +134,7 @@ test_doubleround (cruft::TAP::logger &tap)
|
||||
tap.expect_eq (
|
||||
cruft::crypto::stream::salsa::doubleround (TESTS[i].a),
|
||||
TESTS[i].b,
|
||||
"doubleround %zu",
|
||||
"doubleround {}",
|
||||
i);
|
||||
}
|
||||
|
||||
@ -202,7 +202,7 @@ test_salsa20 (cruft::TAP::logger &tap)
|
||||
tap.expect_eq (
|
||||
cruft::crypto::stream::salsa20 (TESTS[i].a),
|
||||
TESTS[i].b,
|
||||
"salsa20 %zu",
|
||||
"salsa20 {}",
|
||||
i);
|
||||
|
||||
struct {
|
||||
|
Loading…
Reference in New Issue
Block a user