aboutsummaryrefslogtreecommitdiff
path: root/tests/BTLS/TestUtilities.hs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/BTLS/TestUtilities.hs')
-rw-r--r--tests/BTLS/TestUtilities.hs4
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/BTLS/TestUtilities.hs b/tests/BTLS/TestUtilities.hs
index 01e57bb..b8a83c0 100644
--- a/tests/BTLS/TestUtilities.hs
+++ b/tests/BTLS/TestUtilities.hs
@@ -17,6 +17,7 @@
module BTLS.TestUtilities
( abbreviate
, hex
+ , showHex
) where
import qualified Data.ByteString.Base16 as Base16
@@ -47,3 +48,6 @@ hex s =
case Base16.decode s of
(r, "") -> r
_ -> error $ "invalid hex string " ++ unpack s
+
+showHex :: ByteString -> String
+showHex = unpack . Base16.encode