]> git.rkrishnan.org Git - functorrent.git/blobdiff - test/BencodeTests.hs
DONOTUSE quickcheck tests do not terminate
[functorrent.git] / test / BencodeTests.hs
index d8896437f9c0efc4a051b6536f94077866d8e419..8e54e93e1e431de55175092bad4e560eaa654b99 100644 (file)
@@ -24,9 +24,13 @@ tests = hspec $ do
         let encoded = encode (Bint i)
             decoded = decode encoded
         in Right (Bint i) == decoded
-  -- describe "Bencode property tests" $ do
-  --   it "encode/decode" $ do
-  --     property $ \bval ->
-  --       let encoded = encode bval
-  --           decoded = decode encoded
-  --       in Right bval == decoded
+    it "encode/decode blist tests" $ do
+      property $ \bval ->
+        let encoded = encode (Blist (take 1 bval))
+            decoded = decode encoded
+        in Right (Blist (take 1 bval)) == decoded
+    -- it "encode/decode" $ do
+    --   property $ \bval ->
+    --     let encoded = encode bval
+    --         decoded = decode encoded
+    --     in Right bval == decoded