From e6c7fcc59856893a4947925f0dddc3a44b74a48a Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Tue, 2 Feb 2021 21:09:10 -0800 Subject: Fixed some compiler warnings in tests. --- test/Tests/Command.hs | 5 ++--- test/Tests/Helpers.hs | 3 --- test/Tests/Old.hs | 9 +-------- 3 files changed, 3 insertions(+), 14 deletions(-) diff --git a/test/Tests/Command.hs b/test/Tests/Command.hs index bbfa62dea..8118e9759 100644 --- a/test/Tests/Command.hs +++ b/test/Tests/Command.hs @@ -19,12 +19,11 @@ import Data.Algorithm.Diff import System.Environment.Executable (getExecutablePath) import qualified Data.ByteString as BS import qualified Data.Text as T -import Data.List (isSuffixOf, intercalate) -import Data.Maybe (catMaybes) +import Data.List (isSuffixOf) import System.Directory import qualified System.Environment as Env import System.Exit -import System.FilePath (joinPath, splitDirectories, takeDirectory, ()) +import System.FilePath (takeDirectory, ()) import System.IO (hPutStr, stderr) import System.IO.Unsafe (unsafePerformIO) import System.Process diff --git a/test/Tests/Helpers.hs b/test/Tests/Helpers.hs index a4a3c0af5..813c80adb 100644 --- a/test/Tests/Helpers.hs +++ b/test/Tests/Helpers.hs @@ -26,10 +26,7 @@ import Prelude import Data.Algorithm.Diff import qualified Data.Map as M import Data.Text (Text, unpack) -import System.Directory -import System.Environment.Executable (getExecutablePath) import System.Exit -import System.FilePath import Test.Tasty import Test.Tasty.HUnit import Text.Pandoc.Builder (Blocks, Inlines, doc, plain) diff --git a/test/Tests/Old.hs b/test/Tests/Old.hs index 528388c51..a031700a6 100644 --- a/test/Tests/Old.hs +++ b/test/Tests/Old.hs @@ -15,10 +15,8 @@ module Tests.Old (tests) where import Prelude import Data.Algorithm.Diff -import Data.List (intercalate) -import Data.Maybe (catMaybes) import System.Exit -import System.FilePath (joinPath, splitDirectories, (<.>), ()) +import System.FilePath ((<.>), ()) import qualified System.Environment as Env import System.Environment.Executable (getExecutablePath) import Text.Pandoc.Process (pipeProcess) @@ -353,8 +351,3 @@ compareValues norm options expected actual = do "\n--- " ++ norm ++ "\n+++ " ++ cmd ++ "\n" ++ showDiff (1,1) diff ++ dash - -findDynlibDir :: [FilePath] -> Maybe FilePath -findDynlibDir [] = Nothing -findDynlibDir ("build":xs) = Just $ joinPath (reverse xs) "build" -findDynlibDir (_:xs) = findDynlibDir xs -- cgit v1.2.3