diff --git a/math-programming-tests.cabal b/math-programming-tests.cabal
--- a/math-programming-tests.cabal
+++ b/math-programming-tests.cabal
@@ -1,6 +1,6 @@
 cabal-version:       2.4
 name:                math-programming-tests
-version:             0.5.0
+version:             0.5.1
 synopsis:            Utility functions for testing implementations of the math-programming library.
 description:         Please see the <https://github.com/prsteele/math-programming/blob/main/README.md README on GitHub>.
 bug-reports:         https://github.com/prsteele/math-programming/issues
@@ -33,7 +33,7 @@
                    , microlens        ^>=0.4
                    , microlens-th     ^>=0.4
                    , microlens-mtl    ^>=0.2
-                   , hspec            ^>=2.8
+                   , hspec            >=2.8 && <3
                    , QuickCheck       ^>=2.14
                    , random           ^>=1.2
                    , mtl              ^>=2.2
