diff --git a/CHANGES.txt b/CHANGES.txt
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -57,3 +57,11 @@
 Added Semigroup instance.
 Enabled "cabal test".
 Master repository now on GitHub.
+
+Version 0.5.0
+-------------
+
+Added Ord instance.
+Added instances for DiscreteOrdered for Data.Int and Data.Word types.
+Made test dependencies optional.
+
diff --git a/Data/Ranged/Boundaries.hs b/Data/Ranged/Boundaries.hs
--- a/Data/Ranged/Boundaries.hs
+++ b/Data/Ranged/Boundaries.hs
@@ -1,3 +1,5 @@
+{-# LANGUAGE CPP #-}
+
 -----------------------------------------------------------------------------
 -- |
 -- Module      :  Data.Ranged.Boundaries
@@ -19,8 +21,12 @@
    (/>/)
 ) where
 
+import Data.Int
 import Data.Ratio
+import Data.Word
+#ifdef WITH_TESTS
 import Test.QuickCheck
+#endif
 
 infix 4 />/
 
@@ -75,6 +81,42 @@
    adjacent = boundedAdjacent
    adjacentBelow = boundedBelow
 
+instance DiscreteOrdered Word where
+   adjacent = boundedAdjacent
+   adjacentBelow = boundedBelow
+
+instance DiscreteOrdered Word8 where
+   adjacent = boundedAdjacent
+   adjacentBelow = boundedBelow
+
+instance DiscreteOrdered Word16 where
+   adjacent = boundedAdjacent
+   adjacentBelow = boundedBelow
+
+instance DiscreteOrdered Word32 where
+   adjacent = boundedAdjacent
+   adjacentBelow = boundedBelow
+
+instance DiscreteOrdered Word64 where
+   adjacent = boundedAdjacent
+   adjacentBelow = boundedBelow
+
+instance DiscreteOrdered Int8 where
+  adjacent = boundedAdjacent
+  adjacentBelow = boundedBelow
+
+instance DiscreteOrdered Int16 where
+  adjacent = boundedAdjacent
+  adjacentBelow = boundedBelow
+
+instance DiscreteOrdered Int32 where
+  adjacent = boundedAdjacent
+  adjacentBelow = boundedBelow
+
+instance DiscreteOrdered Int64 where
+  adjacent = boundedAdjacent
+  adjacentBelow = boundedBelow
+  
 instance DiscreteOrdered Integer where
    adjacent = enumAdjacent
    adjacentBelow = Just . pred
@@ -210,6 +252,7 @@
                BoundaryBelowAll -> EQ
                _        -> LT
 
+#ifdef WITH_TESTS
 -- QuickCheck Generator
 
 instance Arbitrary a => Arbitrary (Boundary a) where
@@ -227,3 +270,4 @@
    coarbitrary (BoundaryBelow v)  = variant (2 :: Int) . coarbitrary v
    coarbitrary (BoundaryAbove v)  = variant (3 :: Int) . coarbitrary v
 
+#endif
diff --git a/Data/Ranged/RangedSet.hs b/Data/Ranged/RangedSet.hs
--- a/Data/Ranged/RangedSet.hs
+++ b/Data/Ranged/RangedSet.hs
@@ -1,3 +1,5 @@
+{-# LANGUAGE CPP #-}
+
 module Data.Ranged.RangedSet (
    -- ** Ranged Set Type
    RSet,
@@ -23,6 +25,8 @@
    -- ** Useful Sets
    rSetEmpty,
    rSetFull,
+
+#ifdef WITH_TESTS
    -- ** QuickCheck Properties
    -- *** Construction
    prop_validNormalised,
@@ -54,13 +58,17 @@
    prop_union_associates,
    prop_de_morgan_intersection,
    prop_de_morgan_union,
+#endif
 ) where
 
 import Data.Ranged.Boundaries
 import Data.Ranged.Ranges
 
 import Data.List
+
+#ifdef WITH_TESTS
 import Test.QuickCheck
+#endif
 
 infixl 7 -/\-
 infixl 6 -\/-, -!-
@@ -69,7 +77,7 @@
 -- | An RSet (for Ranged Set) is a list of ranges.  The ranges must be sorted
 -- and not overlap.
 newtype DiscreteOrdered v => RSet v = RSet {rSetRanges :: [Range v]}
-   deriving (Eq, Show)
+   deriving (Show, Eq, Ord)
 
 instance DiscreteOrdered a => Semigroup (RSet a) where
    (<>) = rSetUnion
@@ -246,6 +254,7 @@
             Nothing -> []
 
 
+#ifdef WITH_TESTS
 -- QuickCheck Generators
 
 instance (Arbitrary v, DiscreteOrdered v, Show v) =>
@@ -485,3 +494,5 @@
 prop_de_morgan_union :: (DiscreteOrdered a) => RSet a -> RSet a -> Bool
 prop_de_morgan_union rs1 rs2 =
    rSetNegation (rs1 -\/- rs2) == (rSetNegation rs1 -/\- rSetNegation rs2)
+
+#endif
diff --git a/Data/Ranged/Ranges.hs b/Data/Ranged/Ranges.hs
--- a/Data/Ranged/Ranges.hs
+++ b/Data/Ranged/Ranges.hs
@@ -1,3 +1,5 @@
+{-# LANGUAGE CPP #-}
+
 -----------------------------------------------------------------------------
 --
 -- Module      :  Data.Ranged.Ranges
@@ -29,6 +31,8 @@
    rangeIntersection,
    rangeUnion,
    rangeDifference,
+
+#ifdef WITH_TESTS
    -- ** QuickCheck properties
    prop_unionRange,
    prop_unionRangeLength,
@@ -42,13 +46,17 @@
    prop_emptyNonSingleton,
    prop_fullNonSingleton,
    prop_nonSingleton,
-   prop_intSingleton
+   prop_intSingleton,
+#endif
 ) where
 
 import Control.Monad
 import Data.Ranged.Boundaries
 import Data.Maybe
+
+#ifdef WITH_TESTS
 import Test.QuickCheck
+#endif
 
 -- | A Range has upper and lower boundaries.
 data Ord v => Range v = Range {rangeLower, rangeUpper :: Boundary v}
@@ -213,6 +221,7 @@
       intersects = (max lower1 lower2) < (min upper1 upper2)
 
 
+#ifdef WITH_TESTS
 -- QuickCheck generators
 
 instance (Arbitrary v,  DiscreteOrdered v, Show v) =>
@@ -356,4 +365,4 @@
       rangeAround v1 v2 = return Range `ap` genBound v1 `ap` genBound v2
       genBound v = elements [BoundaryAbove v, BoundaryBelow v]
 
-
+#endif
diff --git a/Ranged-sets.cabal b/Ranged-sets.cabal
--- a/Ranged-sets.cabal
+++ b/Ranged-sets.cabal
@@ -1,10 +1,10 @@
 name: Ranged-sets
-version: 0.4.0
+version: 0.5.0
 cabal-version: 1.24
 build-type: Simple
 license: BSD3
 license-file: LICENSE.txt
-copyright: Paul Johnson, 2005, 2006, 2007, 2008, 2019
+copyright: Paul Johnson, 2005, 2006, 2007, 2008, 2019, 2025
 maintainer: paul@cogito.org.uk
 stability: beta
 homepage: https://github.com/PaulJohnson/Ranged-sets
@@ -20,10 +20,18 @@
              >    ("F" <= s < "G")
 category: Data
 author: Paul Johnson
-extra-source-files: CHANGES.txt README.txt
+extra-doc-files: CHANGES.txt README.txt
 
+flag with-tests
+    description: Include unit tests / extra  instances.
+    default: True
+    manual: False
+
 library
-    build-depends: HUnit -any, QuickCheck >=2, base >=4 && <5
+    build-depends: base >=4.11 && <5
+    if flag(with-tests)
+        cpp-options: -DWITH_TESTS
+        build-depends: QuickCheck >=2 && < 3
     exposed-modules: Data.Ranged Data.Ranged.Ranges
                  Data.Ranged.RangedSet Data.Ranged.Boundaries
     exposed: True
@@ -36,10 +44,10 @@
     default-language: Haskell2010
     main-is: Main.hs
     hs-source-dirs: tests .
+    cpp-options: -DWITH_TESTS
     other-modules: Data.Ranged Data.Ranged.Ranges
                  Data.Ranged.RangedSet Data.Ranged.Boundaries
     build-depends:
         base >= 4 && < 5,
         HUnit,
         QuickCheck
-    
