From 3c7f12c10caca196a970c0cc8b6c46945c9dee58 Mon Sep 17 00:00:00 2001 From: Sam Truzjan Date: Wed, 5 Mar 2014 00:35:47 +0400 Subject: Minor refactoring --- tests/Network/BitTorrent/DHT/QuerySpec.hs | 4 ++-- tests/Network/BitTorrent/DHT/RoutingSpec.hs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'tests/Network/BitTorrent/DHT') diff --git a/tests/Network/BitTorrent/DHT/QuerySpec.hs b/tests/Network/BitTorrent/DHT/QuerySpec.hs index 33114b40..d25bd120 100644 --- a/tests/Network/BitTorrent/DHT/QuerySpec.hs +++ b/tests/Network/BitTorrent/DHT/QuerySpec.hs @@ -18,7 +18,7 @@ import Network.BitTorrent.DHT.TestData myAddr :: NodeAddr IPv4 -myAddr = "0.0.0.0:8000" +myAddr = "0.0.0.0:0" nullLogger :: LogFun nullLogger _ _ _ _ = return () @@ -37,7 +37,7 @@ getBootInfo = do simpleDHT [] $ pingQ startAddr spec :: Spec -spec = do +spec = parallel $ do describe "environment" $ do describe "test node" $ do it "is alive" $ do diff --git a/tests/Network/BitTorrent/DHT/RoutingSpec.hs b/tests/Network/BitTorrent/DHT/RoutingSpec.hs index 788c4341..c4a33357 100644 --- a/tests/Network/BitTorrent/DHT/RoutingSpec.hs +++ b/tests/Network/BitTorrent/DHT/RoutingSpec.hs @@ -27,7 +27,7 @@ runSimulation :: Eq ip => Env ip -> Routing ip a -> Maybe a runSimulation e m = evalState (runRouting ping closest timestamp m) e where ping addr = gets (L.elem addr . network) - closest nid = undefined + closest nid = error "runSimulation" timestamp = gets currentTime instance Arbitrary ip => Arbitrary (Env ip) where -- cgit v1.2.3