diff --git a/kmeans-par.cabal b/kmeans-par.cabal
--- a/kmeans-par.cabal
+++ b/kmeans-par.cabal
@@ -1,5 +1,5 @@
 name:                kmeans-par
-version:             1.5.0
+version:             1.5.1
 synopsis:            Sequential and parallel implementations of Lloyd's algorithm.
 license:             MIT
 license-file:        LICENSE
@@ -10,20 +10,66 @@
 cabal-version:       >=1.10
 
 library
-  exposed-modules:     Algorithms.Lloyd.Sequential,
-                       Algorithms.Lloyd.Strategies
-  other-modules:       Data.Functor.Extras,
-                       Data.Vector.Split
-  other-extensions:    ViewPatterns 
-  build-depends:       base == 4.*, vector, semigroups, parallel, metric
-  hs-source-dirs:      src
-  ghc-options:         -threaded -O2 -with-rtsopts=-N -rtsopts
-  default-language:    Haskell2010
+  exposed-modules:
+    Algorithms.Lloyd.Sequential,
+    Algorithms.Lloyd.Strategies
+  other-modules:
+    Data.Functor.Extras,
+    Data.Vector.Split
+  other-extensions:
+    ViewPatterns 
+  build-depends:
+    base == 4.*,
+    vector,
+    semigroups,
+    parallel,
+    metric
+  hs-source-dirs:
+    src
+  ghc-options:
+    -threaded -O2 -with-rtsopts=-N -rtsopts
+  default-language:
+    Haskell2010
 
 benchmark kmeans-benchmark
-  type:             exitcode-stdio-1.0
-  main-is:          Main.lhs
-  hs-source-dirs:   benchmark
-  build-depends:    base == 4.*, random, criterion, normaldistribution, kmeans-par, deepseq, vector, metric
-  ghc-options:      -threaded -O2 -with-rtsopts=-N -rtsopts
-  default-language: Haskell2010
+  type:
+    exitcode-stdio-1.0
+  main-is:
+    Main.lhs
+  hs-source-dirs:
+    benchmark
+  build-depends:
+    base == 4.*,
+    random,
+    criterion,
+    normaldistribution,
+    kmeans-par,
+    deepseq,
+    vector,
+    metric
+  ghc-options:
+    -threaded -O2 -with-rtsopts=-N -rtsopts
+  default-language:
+    Haskell2010
+
+test-suite spec
+  type: 
+    exitcode-stdio-1.0
+  hs-source-dirs:
+    src,
+    test
+  main-is:
+    Spec.hs
+  build-depends:
+    base == 4.*,
+    hspec >= 1.5,
+    normaldistribution,
+    metric,
+    parallel,
+    semigroups,
+    vector,
+    QuickCheck
+  default-language:
+    Haskell2010
+  ghc-options:
+    -threaded -O2 -with-rtsopts=-N -rtsopts
diff --git a/src/Algorithms/Lloyd/Sequential.lhs b/src/Algorithms/Lloyd/Sequential.lhs
--- a/src/Algorithms/Lloyd/Sequential.lhs
+++ b/src/Algorithms/Lloyd/Sequential.lhs
@@ -11,7 +11,8 @@
 >   PointSum(..),
 >   makeNewClusters,
 >   assign,
->   assignPS
+>   assignPS,
+>   step
 > )where
 > 
 > import Prelude hiding (zipWith, map, foldr, replicate, length, zip, head)
@@ -102,8 +103,8 @@
 >   return (cluster, point `d` centroid cluster)
 >
 > assign :: Metric a => (Vector Double -> a) -> Vector Cluster -> Vector Point -> Vector (Vector Point)
-> assign metric clusters points = let nc = length clusters in create $ do
->   vector <- MV.replicate nc empty
+> assign metric clusters points = create $ do
+>   vector <- MV.replicate (length clusters) empty
 >   points `forM_` \point -> do
 >     let cluster  = closestCluster metric clusters point
 >         position = identifier cluster
@@ -118,20 +119,16 @@
 >
 > makeNewClusters :: Vector PointSum -> Vector Cluster
 > makeNewClusters vector = do
->   (pointSum@(PointSum count _), index) <- zip vector $ fromList [0..length vector]
->   guard $ count > 0 -- We don't want an empty PointSum: amongst other 
->                     -- things, this'd lead to division by zero when 
->                     -- computing the centroid.
+>   (pointSum, index) <- zip vector $ fromList [0..length vector]
 >   return $ toCluster index pointSum
 >
 > step :: Metric a => (Vector Double -> a) -> Vector Cluster -> Vector Point -> Vector Cluster
 > step = makeNewClusters ...: assignPS
->
 
 The algorithm consists of iteratively finding the centroid of each existing
 cluster, then reallocating points according to which centroid is closest, until
 convergence. As the algorithm isn't guaranteed to converge, we cut execution if
-convergence hasn't been observed after eighty iterations:
+convergence hasn't been observed some provided number of iterations:
 
 > newtype ExpectDivergent = ExpectDivergent { expectDivergent :: Int }
 >
diff --git a/src/Algorithms/Lloyd/Strategies.lhs b/src/Algorithms/Lloyd/Strategies.lhs
--- a/src/Algorithms/Lloyd/Strategies.lhs
+++ b/src/Algorithms/Lloyd/Strategies.lhs
@@ -10,7 +10,8 @@
 >   Cluster(..), 
 >   ExpectDivergent(..),
 >   Partitions(..),
->   kmeans
+>   kmeans,
+>   step
 > ) where
 >
 > import Prelude hiding (zipWith, foldr1, map)
diff --git a/test/Spec.hs b/test/Spec.hs
new file mode 100644
--- /dev/null
+++ b/test/Spec.hs
@@ -0,0 +1,1 @@
+{-# OPTIONS_GHC -F -pgmF hspec-discover #-}
