diff --git a/src/Test/Tasty/Discover.hs b/src/Test/Tasty/Discover.hs
--- a/src/Test/Tasty/Discover.hs
+++ b/src/Test/Tasty/Discover.hs
@@ -32,10 +32,12 @@
   tasty info a = TT.testGroup (descriptionOf info) <$> a
 
 nameOf :: TastyInfo -> String
-nameOf info = (fromMaybe "<unnamed>" (getLast (TI.name info)))
+nameOf info =
+  fromMaybe "<unnamed>" (getLast (TI.name info))
 
 descriptionOf :: TastyInfo -> String
-descriptionOf info = (fromMaybe "<undescribed>" (getLast (TI.description info)))
+descriptionOf info =
+  fromMaybe "<undescribed>" (getLast (TI.description info))
 
 name :: String -> TastyInfo
 name n = mempty
diff --git a/src/Test/Tasty/Discover/Internal/Config.hs b/src/Test/Tasty/Discover/Internal/Config.hs
--- a/src/Test/Tasty/Discover/Internal/Config.hs
+++ b/src/Test/Tasty/Discover/Internal/Config.hs
@@ -16,6 +16,7 @@
   ) where
 
 import Data.Maybe            (isJust)
+import GHC.Generics          (Generic)
 import System.Console.GetOpt (ArgDescr (NoArg, ReqArg), ArgOrder (Permute), OptDescr (Option), getOpt')
 import System.FilePath ((</>))
 
@@ -39,7 +40,7 @@
   , noModuleSuffix      :: Bool              -- ^ <<<DEPRECATED>>>: suffix and look in all modules.
   , debug               :: Bool              -- ^ Debug the generated module.
   , treeDisplay         :: Bool              -- ^ Tree display for the test results table.
-  } deriving stock (Show)
+  } deriving stock (Show, Generic)
 
 -- | The default configuration
 defaultConfig :: FilePath -> Config
diff --git a/src/Test/Tasty/Discover/Internal/Generator.hs b/src/Test/Tasty/Discover/Internal/Generator.hs
--- a/src/Test/Tasty/Discover/Internal/Generator.hs
+++ b/src/Test/Tasty/Discover/Internal/Generator.hs
@@ -25,13 +25,14 @@
 import Data.Function   (on)
 import Data.List       (find, groupBy, isPrefixOf, sortOn)
 import Data.Maybe      (fromJust)
+import GHC.Generics    (Generic)
 import System.FilePath (dropExtension, isPathSeparator)
 
 -- | The test type.
 data Test = Test
   { testModule   :: String -- ^ Module name.
   , testFunction :: String -- ^ Function name.
-  } deriving stock (Eq, Show, Ord)
+  } deriving stock (Eq, Show, Generic, Ord)
 
 -- | 'Test' constructor.
 mkTest :: FilePath -> String -> Test
@@ -44,7 +45,7 @@
   , generatorImports  :: [String]        -- ^ Module import path.
   , generatorClass    :: String          -- ^ Generator class.
   , generatorSetup    :: Test -> String  -- ^ Generator setup.
-  }
+  } deriving (Generic)
 
 -- | Module import qualifier.
 qualifyFunction :: Test -> String
diff --git a/src/Test/Tasty/Discover/TastyInfo.hs b/src/Test/Tasty/Discover/TastyInfo.hs
--- a/src/Test/Tasty/Discover/TastyInfo.hs
+++ b/src/Test/Tasty/Discover/TastyInfo.hs
@@ -3,11 +3,12 @@
   ) where
 
 import Data.Monoid
+import GHC.Generics (Generic)
 
 data TastyInfo = TastyInfo
   { name        :: Last String
   , description :: Last String
-  } deriving stock (Eq, Show)
+  } deriving stock (Eq, Show, Generic)
 
 instance Semigroup TastyInfo where
   a <> b = TastyInfo
diff --git a/tasty-discover.cabal b/tasty-discover.cabal
--- a/tasty-discover.cabal
+++ b/tasty-discover.cabal
@@ -1,7 +1,7 @@
 cabal-version: 2.2
 
 name:                   tasty-discover
-version:                5.0.1
+version:                5.0.2
 synopsis:               Test discovery for the tasty framework.
 description:            Automatic test discovery and runner for the tasty framework.
                       
@@ -57,7 +57,8 @@
 common tasty-smallcheck           { build-depends: tasty-smallcheck           >= 0.8      && < 1.0      }
 
 common project-config
-  default-extensions:   DerivingStrategies
+  default-extensions:   DeriveGeneric
+                        DerivingStrategies
   if (impl(ghc >= 9.2.1))
     default-extensions: OverloadedRecordDot
   ghc-options:          -Wall
diff --git a/test/DiscoverTest.hs b/test/DiscoverTest.hs
--- a/test/DiscoverTest.hs
+++ b/test/DiscoverTest.hs
@@ -1,13 +1,13 @@
 {-# LANGUAGE CPP                 #-}
 {-# LANGUAGE OverloadedStrings   #-}
 {-# LANGUAGE ScopedTypeVariables #-}
-{-# LANGUAGE TypeApplications    #-}
 
 module DiscoverTest where
 
 import Data.ByteString.Lazy (ByteString)
 import Data.List
 import Data.String (IsString(..))
+import GHC.Generics (Generic)
 import Test.Hspec (shouldBe)
 import Test.Hspec.Core.Spec (Spec, describe, it)
 import Test.Tasty
@@ -105,6 +105,7 @@
 -- How to add custom support for golden tests.
 
 data GoldenTest = GoldenTest FilePath (IO ByteString)
+  deriving stock (Generic)
 
 instance TD.Tasty GoldenTest where
   tasty info (GoldenTest fp act) = pure $ goldenVsString (TD.descriptionOf info) fp act
