Skip to content

Pass io-manager=native to tests #10398

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import Test.Cabal.Prelude

main = cabalTest $ do
skipUnlessGhcVersion ">= 8.1"
expectBrokenIfWindowsCI 10191 $ withProjectFile "cabal.internal.project" $ do
withProjectFile "cabal.internal.project" $ do
cabal "v2-build" ["exe"]
withPlan $ do
r <- runPlanExe' "I" "exe" []
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@ import Test.Cabal.Prelude

main = cabalTest $ do
skipUnlessGhcVersion ">= 8.1"
ghcVer <- isGhcVersion ">= 9.10"
skipIf "Windows + 9.10.1 (#10191)" (isWindows && ghcVer)
withProjectFile "cabal.external.project" $ do
cabal "v2-build" ["exe"]
withPlan $ do
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import Test.Cabal.Prelude

main = cabalTest $ do
skipUnlessGhcVersion ">= 8.1"
expectBrokenIfWindowsCI 10191 $ withProjectFile "cabal.internal.project" $ do
withProjectFile "cabal.internal.project" $ do
cabal "v2-build" ["exe"]
withPlan $ do
r <- runPlanExe' "I" "exe" []
Expand Down
2 changes: 1 addition & 1 deletion cabal-testsuite/PackageTests/Backpack/T6385/cabal.test.hs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import Test.Cabal.Prelude
main =
cabalTest $ expectBrokenIfWindows 10191 $ withShorterPathForNewBuildStore $ do
cabalTest $ withShorterPathForNewBuildStore $ do
skipUnlessGhcVersion ">= 8.1"
withRepo "repo" $ do
cabal "v2-build" ["T6385"]
6 changes: 6 additions & 0 deletions cabal-testsuite/src/Test/Cabal/Prelude.hs
Original file line number Diff line number Diff line change
Expand Up @@ -356,9 +356,15 @@ cabalGArgs global_args cmd args input = do
[ "--store-dir=" ++ storeDir | Just storeDir <- [testMaybeStoreDir env] ]
++ global_args

rts_args =
if buildOS == Windows
then ["+RTS", "--io-manager=native", "-RTS"]
else []

cabal_args = global_args'
++ [ cmd, marked_verbose ]
++ extra_args
++ rts_args
++ args
defaultRecordMode RecordMarked $ do
recordHeader ["cabal", cmd]
Expand Down
7 changes: 6 additions & 1 deletion cabal-testsuite/src/Test/Cabal/Server.hs
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ import System.Exit
import Data.List (intercalate, isPrefixOf)
import Distribution.Simple.Program.Db
import Distribution.Simple.Program
import Distribution.System
import Control.Exception
import qualified Control.Exception as E
import Control.Monad
Expand Down Expand Up @@ -221,7 +222,11 @@ runMain ref m = do
startServer :: Chan ServerLogMsg -> ScriptEnv -> IO Server
startServer chan senv = do
(prog, _) <- requireProgram verbosity ghcProgram (runnerProgramDb senv)
let ghc_args = runnerGhcArgs senv Nothing ++ ["--interactive", "-v0", "-ignore-dot-ghci"]
let rts_args =
if buildOS == Windows
then ["+RTS", "--io-manager=native", "-RTS"]
else []
ghc_args = runnerGhcArgs senv Nothing ++ ["--interactive", "-v0", "-ignore-dot-ghci"] ++ rts_args
proc_spec = (proc (programPath prog) ghc_args) {
create_group = True,
-- Closing fds is VERY important to avoid
Expand Down
Loading