blob: a01693bb3d7fade6f6ce79f7b571f132473e6082 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
module TestSabadie where
import Codec.Wavefront
import System.Directory
import System.IO
getDataDir :: IO FilePath
getDataDir = do
let tryDir d fallback = do
found <- doesDirectoryExist d
if found then return d else fallback
tryDir "./test-data" $ tryDir "../test-data" (return ".")
main = do
ddir <- getDataDir
r1 <- fromFile (ddir ++ "/01.obj")
print r1
-- Failed: ` vp ` [...]: Failed reading: empty
-- Reason: vp token and blank lines
|