Skip to content

Commit

Permalink
Remove withSourceCopyDir from test
Browse files Browse the repository at this point in the history
  • Loading branch information
noiioiu committed Oct 31, 2024
1 parent bee43d4 commit 032f5b1
Showing 1 changed file with 9 additions and 10 deletions.
19 changes: 9 additions & 10 deletions cabal-testsuite/PackageTests/Init/init-without-git.test.hs
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,14 @@ main = do
ghc_path <- programPathM ghcProgram
cabal_path <- programPathM cabalProgram
withSymlink ghc_path (bin </> "ghc") . withSymlink cabal_path (bin </> "cabal") .
withEnv [("PATH", Just bin)] .
withSourceCopyDir "app" $ do
cwd <- fmap testSourceCopyDir getTestEnv
withEnv [("PATH", Just bin)] $ do
cwd <- fmap testSourceCopyDir getTestEnv

buildOut <- withDirectory cwd $ do
cabalWithStdin "init" ["-i"]
"2\n\n5\n\n\n2\n\n\n\n\n\n\n\n\n\n"
setup "configure" []
setup' "build" ["app"]
buildOut <- withDirectory cwd $ do
cabalWithStdin "init" ["-i"]
"2\n\n5\n\n\n2\n\n\n\n\n\n\n\n\n\n"
setup "configure" []
setup' "build" ["app"]

assertFileDoesContain (cwd </> "app.cabal") "3.0"
assertOutputContains "Linking" buildOut
assertFileDoesContain (cwd </> "app.cabal") "3.0"
assertOutputContains "Linking" buildOut

0 comments on commit 032f5b1

Please sign in to comment.