summaryrefslogtreecommitdiff
path: root/tests/Network/BitTorrent/Exchange/BlockSpec.hs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/Network/BitTorrent/Exchange/BlockSpec.hs')
-rw-r--r--tests/Network/BitTorrent/Exchange/BlockSpec.hs16
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/Network/BitTorrent/Exchange/BlockSpec.hs b/tests/Network/BitTorrent/Exchange/BlockSpec.hs
new file mode 100644
index 00000000..0712a21d
--- /dev/null
+++ b/tests/Network/BitTorrent/Exchange/BlockSpec.hs
@@ -0,0 +1,16 @@
1module Network.BitTorrent.Exchange.BlockSpec (spec) where
2import Control.Applicative
3import Test.Hspec
4import Test.QuickCheck
5
6import Network.BitTorrent.Exchange.Block
7
8
9instance Arbitrary a => Arbitrary (Block a) where
10 arbitrary = Block <$> arbitrary <*> arbitrary <*> arbitrary
11
12instance Arbitrary BlockIx where
13 arbitrary = BlockIx <$> arbitrary <*> arbitrary <*> arbitrary
14
15spec :: Spec
16spec = return () \ No newline at end of file