case torrentToMetainfo fc of
Left _ -> pending
Right metainfo -> do
- announceList metainfo `shouldSatisfy` (not . null)
+ announceList metainfo `shouldSatisfy` (not . null)
+ it "valid piece length" $ do
+ fc <- readFile "data/debian-7.8.0-amd64-CD-1.iso.torrent"
+ case torrentToMetainfo fc of
+ Left _ -> pending
+ Right metainfo -> do
+ let (Just info') = info metainfo
+ pieceLength info' `shouldBe` (524288 :: Integer)