1- {-# LANGUAGE CPP #-}
21{-# LANGUAGE TemplateHaskell #-}
32
43module App.Fossa.VendoredDependencySpec (
@@ -17,14 +16,8 @@ import App.Fossa.VendoredDependency (
1716import Control.Carrier.Lift (sendIO )
1817import Control.Effect.Path (withSystemTempDir )
1918import Path (Abs , Dir , Path , mkRelDir , (</>) )
20- #ifndef mingw32_HOST_OS
21- import Path (mkRelFile , toFilePath )
22- #endif
2319import Path.IO (getCurrentDir )
2420import Test.Effect (it' , shouldContain' )
25- #ifndef mingw32_HOST_OS
26- import Test.Effect (shouldStartWith' )
27- #endif
2821import Test.Fixtures qualified as Fixtures
2922import Test.Hspec (Spec , describe , it , runIO , shouldBe )
3023
@@ -50,19 +43,6 @@ spec = do
5043 compressedFilePath <- sendIO $ withSystemTempDir " fossa-temp" (flippedCompressFile specDir fileToTar)
5144 compressedFilePath `shouldContain'` fileToTar
5245
53- #ifndef mingw32_HOST_OS
54- -- Posix-only: safeSeparators uses System.FilePath.Posix, and the customer
55- -- bug only manifests for Posix-style absolute paths produced by meta-fossa.
56- it' " should write the tarball inside outputDir when fileToTar is absolute" $
57- do
58- let specDir = currDir </> $ (mkRelDir " test/ArchiveUploader/normal" )
59- let absFile = toFilePath (specDir </> $ (mkRelFile " foo" ))
60- (outDirStr, compressedFilePath) <-
61- sendIO . withSystemTempDir " fossa-temp" $ \ out ->
62- (toFilePath out,) <$> compressFile out specDir absFile
63- compressedFilePath `shouldStartWith'` outDirStr
64- #endif
65-
6646 describe " safeSeparators" $ do
6747 it " joins relative path components with underscores" $
6848 safeSeparators " build/base-files" `shouldBe` " build_base-files"
0 commit comments