packages feed

graph-wrapper 0.2.5.1 → 0.2.5.2

raw patch · 2 files changed

+29/−2 lines, 2 filesdep ~containersPVP: major bump suggested

API removals or changes: PVP suggests a major version bump

Dependency ranges changed: containers

API changes (from Hackage documentation)

- Data.Graph.Wrapper: instance Foldable SCC
- Data.Graph.Wrapper: instance Functor SCC
- Data.Graph.Wrapper: instance Show i => Show (SCC i)
- Data.Graph.Wrapper: instance Traversable SCC
- Data.Graph.Wrapper.Internal: gVertexVertexArray :: Graph i v -> Array Vertex v
- Data.Graph.Wrapper.Internal: graph :: Graph i v -> Graph
- Data.Graph.Wrapper.Internal: indexGVertexArray :: Graph i v -> Array Vertex i
- Data.Graph.Wrapper.Internal: instance (Ord i, Show i, Show v) => Show (Graph i v)
- Data.Graph.Wrapper.Internal: instance Foldable (Graph i)
- Data.Graph.Wrapper.Internal: instance Functor (Graph i)
- Data.Graph.Wrapper.Internal: instance Traversable (Graph i)
+ Data.Graph.Wrapper: instance Data.Foldable.Foldable Data.Graph.Wrapper.SCC
+ Data.Graph.Wrapper: instance Data.Traversable.Traversable Data.Graph.Wrapper.SCC
+ Data.Graph.Wrapper: instance GHC.Base.Functor Data.Graph.Wrapper.SCC
+ Data.Graph.Wrapper: instance GHC.Show.Show i => GHC.Show.Show (Data.Graph.Wrapper.SCC i)
+ Data.Graph.Wrapper.Internal: [gVertexVertexArray] :: Graph i v -> Array Vertex v
+ Data.Graph.Wrapper.Internal: [graph] :: Graph i v -> Graph
+ Data.Graph.Wrapper.Internal: [indexGVertexArray] :: Graph i v -> Array Vertex i
+ Data.Graph.Wrapper.Internal: instance (GHC.Classes.Ord i, GHC.Show.Show i, GHC.Show.Show v) => GHC.Show.Show (Data.Graph.Wrapper.Internal.Graph i v)
+ Data.Graph.Wrapper.Internal: instance Data.Foldable.Foldable (Data.Graph.Wrapper.Internal.Graph i)
+ Data.Graph.Wrapper.Internal: instance Data.Traversable.Traversable (Data.Graph.Wrapper.Internal.Graph i)
+ Data.Graph.Wrapper.Internal: instance GHC.Base.Functor (Data.Graph.Wrapper.Internal.Graph i)

Files

graph-wrapper.cabal view
@@ -1,7 +1,7 @@ Cabal-Version:      >= 1.8 Build-Type:         Simple Name:               graph-wrapper-Version:            0.2.5.1+Version:            0.2.5.2 Maintainer:         Max Bolingbroke <batterseapower@hotmail.com>, Sönke Hahn <soenkehahn@gmail.com> Homepage:           https://github.com/soenkehahn/graph-wrapper License:            BSD3@@ -25,7 +25,7 @@     Build-Depends:         base >= 3.0 && < 5.0,         array >= 0.3 && < 0.6,-        containers >= 0.3 && < 0.6+        containers >= 0.3 && < 0.7  test-suite spec     type:@@ -41,3 +41,7 @@         deepseq,         hspec,         QuickCheck+    other-modules:+      Data.Graph.Wrapper+      Data.Graph.Wrapper.Internal+      Data.Graph.WrapperSpec
+ test/Data/Graph/WrapperSpec.hs view
@@ -0,0 +1,23 @@++module Data.Graph.WrapperSpec where+++import           Control.DeepSeq+import           Test.Hspec+import           Test.QuickCheck++import           Data.Graph.Wrapper+++spec :: Spec+spec = do+  describe "fromListLenient" $ do+    it "does not crash" $ do+      property $ \ list ->+        deepseq (toList (fromListLenient list :: Graph Integer ())) True++  describe "reachableVertices" $ do+    context "when the vertex is not in the given graph" $ do+      it "returns the empty list" $ do+        reachableVertices (fromList [] :: Graph Integer ()) 0+          `shouldBe` []