diff options
Diffstat (limited to 'src/tests/test_bigint.cpp')
-rw-r--r-- | src/tests/test_bigint.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/tests/test_bigint.cpp b/src/tests/test_bigint.cpp index a7e00498f..6f3d603db 100644 --- a/src/tests/test_bigint.cpp +++ b/src/tests/test_bigint.cpp @@ -303,6 +303,15 @@ class BigInt_Mod_Test : public Text_Based_Test e %= b; result.test_eq("a %= b", e, c); + // if b fits into a Botan::word test %= operator for words + if(b.bytes() <= sizeof(Botan::word)) + { + Botan::word b_word = b.word_at( 0 ); + e = a; + e %= b_word; + result.test_eq("a %= b (as word)", e, c); + } + return result; } }; |