Command tests: include regular PATH...

...after directory with the test executable.
I want to see if this fixes the CI problem on Windows, which
may be due to problems finding a DLL.
This commit is contained in:
John MacFarlane
2024-04-15 10:19:41 -07:00
parent 0f8086cbd3
commit 96add8b9cc
+3 -1
View File
@@ -89,12 +89,14 @@ setupEnvironment testExePath = do
mldpath <- Env.lookupEnv "LD_LIBRARY_PATH"
mdyldpath <- Env.lookupEnv "DYLD_LIBRARY_PATH"
mpdd <- Env.lookupEnv "pandoc_datadir"
mbpath <- Env.lookupEnv "PATH"
-- Note that Cabal sets the pandoc_datadir environment variable
-- to point to the source directory, since otherwise getDataFilename
-- will look in the data directory into which pandoc will be installed
-- (but has not yet been). So when we spawn a new process with
-- pandoc, we need to make sure this environment variable is set.
return $ ("PATH",takeDirectory testExePath) :
return $ ("PATH",takeDirectory testExePath <>
maybe mempty (searchPathSeparator:) mbpath) :
("TMP",".") :
("LANG","en_US.UTF-8") :
("HOME", "./") :