diff options
author | Sam Truzjan <pxqr.sta@gmail.com> | 2014-04-03 00:58:59 +0400 |
---|---|---|
committer | Sam Truzjan <pxqr.sta@gmail.com> | 2014-04-03 00:58:59 +0400 |
commit | 35a049358dbc84f1b24e8e6d3f7e5e1dc0d5e0ae (patch) | |
tree | 3704c8118943db24c06d538b45531a25c13cb081 /tests | |
parent | 14a90a6848b4fb39cd61459746ca8ea136adffb0 (diff) |
[Client] Add spec item for openMagnet
Diffstat (limited to 'tests')
-rw-r--r-- | tests/Network/BitTorrent/Client/HandleSpec.hs | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/tests/Network/BitTorrent/Client/HandleSpec.hs b/tests/Network/BitTorrent/Client/HandleSpec.hs new file mode 100644 index 00000000..8e16d9b0 --- /dev/null +++ b/tests/Network/BitTorrent/Client/HandleSpec.hs | |||
@@ -0,0 +1,19 @@ | |||
1 | module Network.BitTorrent.Client.HandleSpec (spec) where | ||
2 | import Data.Default | ||
3 | import Test.Hspec | ||
4 | |||
5 | import Data.Torrent.Magnet | ||
6 | import Network.BitTorrent.Client | ||
7 | import Network.BitTorrent.Client.Handle | ||
8 | |||
9 | data_dir :: FilePath | ||
10 | data_dir = "data" | ||
11 | |||
12 | spec :: Spec | ||
13 | spec = do | ||
14 | describe "openMagnet" $ do | ||
15 | it "should add new infohash to index" $ do | ||
16 | simpleClient $ do | ||
17 | _ <- openMagnet data_dir (nullMagnet def) | ||
18 | _ <- getHandle def | ||
19 | return () | ||