summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorSam Truzjan <pxqr.sta@gmail.com>2013-11-23 04:29:59 +0400
committerSam Truzjan <pxqr.sta@gmail.com>2013-11-23 04:29:59 +0400
commite3ee3bf4b174363f55c3af2195bd191e9c0d25b7 (patch)
treeaf432782fe94c10d901c15a1b9579975577edd77 /tests
parented25a297094b483dce06e14d52ced2f93f6dca41 (diff)
Add mainline client implementation id
Diffstat (limited to 'tests')
-rw-r--r--tests/Data/Torrent/ClientSpec.hs4
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/Data/Torrent/ClientSpec.hs b/tests/Data/Torrent/ClientSpec.hs
index 890ee95e..94335ae9 100644
--- a/tests/Data/Torrent/ClientSpec.hs
+++ b/tests/Data/Torrent/ClientSpec.hs
@@ -9,6 +9,10 @@ import Network.BitTorrent.Core.PeerId
9spec :: Spec 9spec :: Spec
10spec = do 10spec = do
11 describe "client info" $ do 11 describe "client info" $ do
12 it "decode mainline encoded peer id" $ do
13 clientInfo "M4-3-6--xxxxxxxxxxxx" `shouldBe` "Mainline-4.3.6"
14 clientInfo "M4-20-8-xxxxxxxxxxxx" `shouldBe` "Mainline-4.20.8"
15
12 it "decode azureus encoded peer id" $ do 16 it "decode azureus encoded peer id" $ do
13 clientInfo "-AZ2060-xxxxxxxxxxxx" `shouldBe` "Azureus-2060" 17 clientInfo "-AZ2060-xxxxxxxxxxxx" `shouldBe` "Azureus-2060"
14 clientInfo "-BS0000-xxxxxxxxxxxx" `shouldBe` "BTSlave-0" 18 clientInfo "-BS0000-xxxxxxxxxxxx" `shouldBe` "BTSlave-0"