diff --git a/cabal-testsuite/PackageTests/CustomTestCoverage/cabal.out b/cabal-testsuite/PackageTests/CustomTestCoverage/cabal.out
index a650ce81c42a8a3292a7fb87ff29abe6cf975c44..8824eb7c6354163e73da2e2128f41dcad36c5144 100644
--- a/cabal-testsuite/PackageTests/CustomTestCoverage/cabal.out
+++ b/cabal-testsuite/PackageTests/CustomTestCoverage/cabal.out
@@ -4,14 +4,20 @@ Build profile: -w ghc-<GHCVER> -O1
 In order, the following will be built:
  - plain-0.1.0.0 *test (first run)
 Configuring plain-0.1.0.0...
-Preprocessing library for plain-0.1.0.0..
-Building library for plain-0.1.0.0..
-Preprocessing test suite 'test' for plain-0.1.0.0..
-Building test suite 'test' for plain-0.1.0.0..
+Preprocessing library for plain-0.1.0.0...
+Building library for plain-0.1.0.0...
+Preprocessing test suite 'test' for plain-0.1.0.0...
+Building test suite 'test' for plain-0.1.0.0...
 Running 1 test suites...
 Test suite test: RUNNING...
 Test suite test: PASS
 Test suite logged to: <ROOT>/cabal.dist/work/./dist/build/<ARCH>/ghc-<GHCVER>/plain-0.1.0.0/test/plain-0.1.0.0-test.log
+<<<<<<< HEAD
 Test coverage report written to <ROOT>/cabal.dist/work/./dist/build/<ARCH>/ghc-<GHCVER>/plain-0.1.0.0/hpc/vanilla/html/test/hpc_index.html
 1 of 1 test suites (1 of 1 test cases) passed.
 Package coverage report written to <ROOT>/cabal.dist/work/./dist/build/<ARCH>/ghc-<GHCVER>/plain-0.1.0.0/hpc/vanilla/html/plain-0.1.0.0/hpc_index.html
+=======
+Package coverage report written to <ROOT>/cabal.dist/work/./dist/build/<ARCH>/ghc-<GHCVER>/plain-0.1.0.0/hpc/vanilla/html/hpc_index.html
+1 of 1 test suites (1 of 1 test cases) passed.
+Package coverage report written to <ROOT>/cabal.dist/work/./dist/build/<ARCH>/ghc-<GHCVER>/plain-0.1.0.0/hpc/vanilla/html/hpc_index.html
+>>>>>>> 2b44677c3 (More consistently pass --package-db flag to tests)
diff --git a/cabal-testsuite/PackageTests/Regression/T9640/cabal.out b/cabal-testsuite/PackageTests/Regression/T9640/cabal.out
index 8ec3628aadb562f861ca187a4a6b9bb1ed1c1dd3..4c0f119823fec2d30156f9e6ad663797054f486a 100644
--- a/cabal-testsuite/PackageTests/Regression/T9640/cabal.out
+++ b/cabal-testsuite/PackageTests/Regression/T9640/cabal.out
@@ -7,8 +7,8 @@ In order, the following will be built:
  - one-custom-0.1.0.0 (lib:one-custom) (requires build)
  - depend-on-custom-with-exe-0.1.0.0 (lib) (first run)
 Configuring one-custom-0.1.0.0...
-Preprocessing library for one-custom-0.1.0.0..
-Building library for one-custom-0.1.0.0..
+Preprocessing library for one-custom-0.1.0.0...
+Building library for one-custom-0.1.0.0...
 Installing library in <PATH>
 Warning: depend-on-custom-with-exe.cabal:16:1: Ignoring trailing fields after sections: "ghc-options"
 Configuring library for depend-on-custom-with-exe-0.1.0.0...
diff --git a/cabal-testsuite/src/Test/Cabal/DecodeShowBuildInfo.hs b/cabal-testsuite/src/Test/Cabal/DecodeShowBuildInfo.hs
index 02c1cb7e733fbc56bbf908f09735e4af7639d7ed..e335d6b93db2b8e84d59f52fd1eb9d0819ace39f 100644
--- a/cabal-testsuite/src/Test/Cabal/DecodeShowBuildInfo.hs
+++ b/cabal-testsuite/src/Test/Cabal/DecodeShowBuildInfo.hs
@@ -21,7 +21,7 @@ import           System.Exit
 --
 -- Results can be read via 'withPlan', 'buildInfoFile' and 'decodeBuildInfoFile'.
 runShowBuildInfo :: [String] -> TestM ()
-runShowBuildInfo args = cabal "build" ("--enable-build-info":args)
+runShowBuildInfo args = noCabalPackageDb $ cabal "build" ("--enable-build-info":args)
 
 -- | Read 'build-info.json' for a given package and component
 -- from disk and record the content. Helpful for defining test-cases
diff --git a/cabal-testsuite/src/Test/Cabal/Prelude.hs b/cabal-testsuite/src/Test/Cabal/Prelude.hs
index 4de40b3a412e6267ab3f7671b251e8f5570893d1..f1656eecaf660dea82e9a9c14cdbc9055bcbff29 100644
--- a/cabal-testsuite/src/Test/Cabal/Prelude.hs
+++ b/cabal-testsuite/src/Test/Cabal/Prelude.hs
@@ -313,7 +313,7 @@ cabalGArgs global_args cmd args input = do
           | cmd `elem` ["v2-sdist", "path"]
           = [ "--project-file=" ++ fp | Just fp <- [testCabalProjectFile env] ]
 
-          | cmd == "v2-clean"
+          | cmd == "v2-clean" || cmd == "clean"
           = [ "--builddir", testDistDir env ]
             ++ [ "--project-file=" ++ fp | Just fp <- [testCabalProjectFile env] ]
 
@@ -322,10 +322,14 @@ cabalGArgs global_args cmd args input = do
             , "-j1" ]
             ++ [ "--project-file=" ++ fp | Just fp <- [testCabalProjectFile env] ]
             ++ ["--package-db=" ++ db | Just db <- [testPackageDbPath env]]
+          | "v1-" `isPrefixOf` cmd
+          = [ "--builddir", testDistDir env ]
+            ++ install_args
 
           | otherwise
-          = [ "--builddir", testDistDir env ] ++
-            install_args
+          = [ "--builddir", testDistDir env ]
+            ++ ["--package-db=" ++ db | Just db <- [testPackageDbPath env]]
+            ++ install_args
 
         install_args
           | cmd == "v1-install" || cmd == "v1-build" = [ "-j1" ]