diff options
author | Sam Truzjan <pxqr.sta@gmail.com> | 2013-09-28 05:39:46 +0400 |
---|---|---|
committer | Sam Truzjan <pxqr.sta@gmail.com> | 2013-09-28 05:39:46 +0400 |
commit | 51fecc396f8c7ccd3f91125d5fbac040051915c6 (patch) | |
tree | a1f4b0f63408d88cd307828c150eac1aae8d44b3 /tests | |
parent | 484e45c985a4a63a21ed9ef553373d58cbed703e (diff) |
Rename BEncode to BValue
Diffstat (limited to 'tests')
-rw-r--r-- | tests/properties.hs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/properties.hs b/tests/properties.hs index 12f3dfc..0d49445 100644 --- a/tests/properties.hs +++ b/tests/properties.hs | |||
@@ -16,7 +16,7 @@ import Data.BEncode | |||
16 | instance Arbitrary B.ByteString where | 16 | instance Arbitrary B.ByteString where |
17 | arbitrary = fmap B.pack arbitrary | 17 | arbitrary = fmap B.pack arbitrary |
18 | 18 | ||
19 | instance Arbitrary BEncode where | 19 | instance Arbitrary BValue where |
20 | arbitrary = frequency | 20 | arbitrary = frequency |
21 | [ (50, BInteger <$> arbitrary) | 21 | [ (50, BInteger <$> arbitrary) |
22 | , (40, BString <$> arbitrary) | 22 | , (40, BString <$> arbitrary) |
@@ -24,7 +24,7 @@ instance Arbitrary BEncode where | |||
24 | ] | 24 | ] |
25 | 25 | ||
26 | 26 | ||
27 | prop_EncDec :: BEncode -> Bool | 27 | prop_EncDec :: BValue -> Bool |
28 | prop_EncDec x = case decode (L.toStrict (encode x)) of | 28 | prop_EncDec x = case decode (L.toStrict (encode x)) of |
29 | Left _ -> False | 29 | Left _ -> False |
30 | Right x' -> x == x' | 30 | Right x' -> x == x' |