diff --git a/CHANGELOG.txt b/CHANGELOG.txt
--- a/CHANGELOG.txt
+++ b/CHANGELOG.txt
@@ -1,3 +1,16 @@
+0.7.6, 2016-06-28:
+	Update dependencies to allow filepath-1.4.
+
+	Added Cabal Source-Repository metadata, pointing to GitHub.
+
+	Integrated tests with Cabal so that they can be run with "cabal test".
+
+	Got rid of deprecation warnings by using Control.Monad.Trans.Except
+	instead of Control.Monad.Trans.Error.
+
+	Added Semigroup instance, bringing in a new dependency on semigroups on
+	pre-8.0 GHC versions.
+
 0.7.5, 2014-05-08:
 	Update dependencies to allow transformers-0.4.
 
diff --git a/Glob.cabal b/Glob.cabal
--- a/Glob.cabal
+++ b/Glob.cabal
@@ -1,7 +1,7 @@
-Cabal-Version: >= 1.6
+Cabal-Version: >= 1.9.2
 
 Name:        Glob
-Version:     0.7.5
+Version:     0.7.6
 Homepage:    http://iki.fi/matti.niemenmaa/glob/
 Synopsis:    Globbing library
 Category:    System
@@ -19,18 +19,22 @@
 Extra-Source-Files: CHANGELOG.txt
                     CREDITS.txt
                     README.txt
-                    tests/README.txt
-                    tests/*.hs
-                    tests/Tests/*.hs
 
+Source-Repository head
+  Type: git
+  Location: https://github.com/Deewiant/glob
+
 Library
    Build-Depends: base         >= 4 && < 5
                 , containers   <  0.6
                 , directory    <  1.3
                 , dlist        >= 0.4 && < 0.8
-                , filepath     >= 1.1 && < 1.4
+                , filepath     >= 1.1 && < 1.5
                 , transformers >= 0.2 && < 0.6
 
+   if impl(ghc < 8.0)
+      Build-Depends: semigroups >= 0.18 && < 0.19
+
    if os(windows)
       Build-Depends: Win32 == 2.*
 
@@ -41,3 +45,41 @@
                     System.FilePath.Glob.Match
                     System.FilePath.Glob.Simplify
                     System.FilePath.Glob.Utils
+
+Test-Suite glob-tests
+   type: exitcode-stdio-1.0
+
+   hs-source-dirs: ., tests
+   main-is: Main.hs
+
+   Build-Depends: base                       >= 4 && < 5
+                , containers                 <  0.6
+                , directory                  <  1.3
+                , dlist                      >= 0.4 && < 0.8
+                , filepath                   >= 1.1 && < 1.5
+                , transformers               >= 0.2 && < 0.6
+                , HUnit                      == 1.2.*
+                , QuickCheck                 >= 2 && < 3
+                , test-framework             >= 0.2 && < 1
+                , test-framework-hunit       >= 0.2 && < 1
+                , test-framework-quickcheck2 >= 0.3 && < 1
+
+   if impl(ghc < 8.0)
+      Build-Depends: semigroups >= 0.18 && < 0.19
+
+   if os(windows)
+      Build-Depends: Win32 == 2.*
+
+   Other-Modules: System.FilePath.Glob.Base
+                  System.FilePath.Glob.Directory
+                  System.FilePath.Glob.Match
+                  System.FilePath.Glob.Simplify
+                  System.FilePath.Glob.Utils
+                  Tests.Base
+                  Tests.Compiler
+                  Tests.Instances
+                  Tests.Matcher
+                  Tests.Optimizer
+                  Tests.Regression
+                  Tests.Simplifier
+                  Tests.Utils
diff --git a/LICENSE.txt b/LICENSE.txt
--- a/LICENSE.txt
+++ b/LICENSE.txt
@@ -2,7 +2,7 @@
 the code are held by whoever wrote the code in question: see CREDITS.txt for a
 list of authors.
 
-Copyright (c) 2008-2012 <authors>
+Copyright (c) 2008-2016 <authors>
 All rights reserved.
 
 Redistribution and use in source and binary forms, with or without
diff --git a/System/FilePath/Glob/Base.hs b/System/FilePath/Glob/Base.hs
--- a/System/FilePath/Glob/Base.hs
+++ b/System/FilePath/Glob/Base.hs
@@ -21,13 +21,15 @@
 
 import Control.Arrow                     (first)
 import Control.Monad.Trans.Class         (lift)
-import Control.Monad.Trans.Error         (ErrorT, runErrorT, throwError)
+import Control.Monad.Trans.Except        (ExceptT, runExceptT, throwE)
 import Control.Monad.Trans.Writer.Strict (Writer, runWriter, tell)
 import Control.Exception                 (assert)
 import Data.Char                         (isDigit, isAlpha, toLower)
 import Data.List                         (find, sortBy)
+import Data.List.NonEmpty                (toList)
 import Data.Maybe                        (fromMaybe)
 import Data.Monoid                       (Monoid, mappend, mempty, mconcat)
+import Data.Semigroup                    (Semigroup, (<>), sconcat, stimes)
 import System.FilePath                   ( pathSeparator, extSeparator
                                          , isExtSeparator, isPathSeparator
                                          )
@@ -151,10 +153,15 @@
       [(compile xs, rest)]
 #endif
 
+instance Semigroup Pattern where
+   Pattern a <> Pattern b = optimize $ Pattern (a <> b)
+   sconcat = optimize . Pattern . concatMap unPattern . toList
+   stimes n (Pattern a) = optimize $ Pattern (stimes n a)
+
 instance Monoid Pattern where
-   mempty                          = Pattern []
-   mappend (Pattern a) (Pattern b) = optimize . Pattern $ (a ++ b)
-   mconcat                         = optimize . Pattern . concatMap unPattern
+   mempty  = Pattern []
+   mappend = (<>)
+   mconcat = optimize . Pattern . concatMap unPattern
 
 -- |Options which can be passed to the 'tryCompileWith' or 'compileWith'
 -- functions: with these you can selectively toggle certain features at compile
@@ -434,22 +441,22 @@
    start ('-':xs) = run $ char '-' xs
    start xs       = run $ go xs
 
-   run :: ErrorT String (Writer CharRange) String
+   run :: ExceptT String (Writer CharRange) String
        -> (Either String CharRange, String)
-   run m = case runWriter.runErrorT $ m of
+   run m = case runWriter.runExceptT $ m of
                 (Left   err,  _) -> (Left err, [])
                 (Right rest, cs) -> (Right cs, rest)
 
-   go :: String -> ErrorT String (Writer CharRange) String
+   go :: String -> ExceptT String (Writer CharRange) String
    go ('[':':':xs) | characterClasses opts = readClass xs
    go (    ']':xs) = return xs
    go (      c:xs) =
       if not (pathSepInRanges opts) && isPathSeparator c
-         then throwError "compile :: path separator within []"
+         then throwE "compile :: path separator within []"
          else char c xs
-   go []           = throwError "compile :: unclosed [] in pattern"
+   go []           = throwE "compile :: unclosed [] in pattern"
 
-   char :: Char -> String -> ErrorT String (Writer CharRange) String
+   char :: Char -> String -> ExceptT String (Writer CharRange) String
    char c ('-':x:xs) =
       if x == ']'
          then ltell [Left c, Left '-'] >> return xs
@@ -457,13 +464,13 @@
 
    char c xs = ltell [Left c] >> go xs
 
-   readClass :: String -> ErrorT String (Writer CharRange) String
+   readClass :: String -> ExceptT String (Writer CharRange) String
    readClass xs = let (name,end) = span isAlpha xs
                    in case end of
                            ':':']':rest -> charClass name            >> go rest
                            _            -> ltell [Left '[',Left ':'] >> go xs
 
-   charClass :: String -> ErrorT String (Writer CharRange) ()
+   charClass :: String -> ExceptT String (Writer CharRange) ()
    charClass name =
       -- The POSIX classes
       --
@@ -483,7 +490,7 @@
            "upper"  -> ltell [upper]
            "xdigit" -> ltell [digit, Right ('A','F'), Right ('a','f')]
            _        ->
-              throwError ("compile :: unknown character class '" ++name++ "'")
+              throwE ("compile :: unknown character class '" ++name++ "'")
 
    digit  = Right ('0','9')
    upper  = Right ('A','Z')
diff --git a/tests/README.txt b/tests/README.txt
deleted file mode 100644
--- a/tests/README.txt
+++ /dev/null
@@ -1,15 +0,0 @@
-These are the tests for the Glob library by Matti Niemenmaa, and should reside
-in a subdirectory of the Glob distribution.
-
-To run the tests, run 'Main.hs'.
-
-You'll need the following packages:
-
-  base                      >= 3.* && < 5
-, Glob                      == 0.*
-, filepath                  == 1.*
-, HUnit                     == 1.2.*
-, QuickCheck                >= 1.1 && < 2
-, test-framework            >= 0.2 && < 1
-, test-framework-hunit      >= 0.2 && < 1
-, test-framework-quickcheck >= 0.2 && < 1
diff --git a/tests/Tests/Compiler.hs b/tests/Tests/Compiler.hs
--- a/tests/Tests/Compiler.hs
+++ b/tests/Tests/Compiler.hs
@@ -3,7 +3,7 @@
 module Tests.Compiler (tests) where
 
 import Test.Framework
-import Test.Framework.Providers.QuickCheck
+import Test.Framework.Providers.QuickCheck2
 
 import System.FilePath.Glob.Base (tryCompileWith, compile, decompile)
 
diff --git a/tests/Tests/Instances.hs b/tests/Tests/Instances.hs
--- a/tests/Tests/Instances.hs
+++ b/tests/Tests/Instances.hs
@@ -4,7 +4,7 @@
 
 import Data.Monoid (mempty, mappend)
 import Test.Framework
-import Test.Framework.Providers.QuickCheck
+import Test.Framework.Providers.QuickCheck2
 import Test.QuickCheck ((==>))
 
 import System.FilePath.Glob.Base (tryCompileWith)
diff --git a/tests/Tests/Matcher.hs b/tests/Tests/Matcher.hs
--- a/tests/Tests/Matcher.hs
+++ b/tests/Tests/Matcher.hs
@@ -4,7 +4,7 @@
 
 import Control.Monad (ap)
 import Test.Framework
-import Test.Framework.Providers.QuickCheck
+import Test.Framework.Providers.QuickCheck2
 import Test.QuickCheck ((==>))
 
 import System.FilePath (isExtSeparator, isPathSeparator)
diff --git a/tests/Tests/Optimizer.hs b/tests/Tests/Optimizer.hs
--- a/tests/Tests/Optimizer.hs
+++ b/tests/Tests/Optimizer.hs
@@ -3,7 +3,7 @@
 module Tests.Optimizer (tests) where
 
 import Test.Framework
-import Test.Framework.Providers.QuickCheck
+import Test.Framework.Providers.QuickCheck2
 
 import System.FilePath.Glob.Base  (tokenize, optimize)
 import System.FilePath.Glob.Match
diff --git a/tests/Tests/Simplifier.hs b/tests/Tests/Simplifier.hs
--- a/tests/Tests/Simplifier.hs
+++ b/tests/Tests/Simplifier.hs
@@ -3,7 +3,7 @@
 module Tests.Simplifier (tests) where
 
 import Test.Framework
-import Test.Framework.Providers.QuickCheck
+import Test.Framework.Providers.QuickCheck2
 
 import System.FilePath.Glob.Base (tryCompileWith)
 import System.FilePath.Glob.Match
diff --git a/tests/Tests/Utils.hs b/tests/Tests/Utils.hs
--- a/tests/Tests/Utils.hs
+++ b/tests/Tests/Utils.hs
@@ -4,7 +4,7 @@
 
 import Data.Maybe
 import Test.Framework
-import Test.Framework.Providers.QuickCheck
+import Test.Framework.Providers.QuickCheck2
 import Test.QuickCheck
 
 import System.FilePath.Glob.Utils
diff --git a/tests/Utils.hs b/tests/Utils.hs
deleted file mode 100644
--- a/tests/Utils.hs
+++ /dev/null
@@ -1,11 +0,0 @@
--- File created: 2008-10-15 20:50:31
-
-module Utils where
-
-fromRight (Right x) = x
-fromRight _         = error "fromRight :: Left"
-
-isRight (Right _) = True
-isRight _         = False
-
-a --> b = not a || b
