Skip to content

Commit 3d61f8b

Browse files
MartinSStewartsupermario
authored andcommitted
Make paths relative
1 parent 4755877 commit 3d61f8b

File tree

1 file changed

+6
-15
lines changed

1 file changed

+6
-15
lines changed

test/Test/WebGL.hs

Lines changed: 6 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ import qualified Lamdera.AppConfig
1515
import qualified Lamdera.Update
1616
import qualified Lamdera.Compile
1717
import qualified Lamdera.Evergreen.Snapshot
18+
import qualified Lamdera.Relative
1819
import Test.Helpers
1920
import Test.Check
2021

@@ -28,22 +29,12 @@ import qualified Ext.Common
2829

2930
suite :: Test ()
3031
suite = tests
31-
[ scope "make Elm app containing extension directive in shader" $
32-
let
33-
elmStuffFolder = "/Users/martinstewart/Documents/GitHub/compiler/test/scenario-webgl-extensions/elm-stuff"
32+
[ scope "make Elm app containing extension directive in shader" $ do
33+
project <- io $ Lamdera.Relative.findDir "test/scenario-webgl-extensions"
3434

35-
setup = do
36-
rmdir elmStuffFolder
35+
_ <- io $ rmdir (project </> "elm-stuff")
3736

38-
cleanup _ = do
39-
rmdir elmStuffFolder
37+
actual <- catchOutput $ Lamdera.Compile.makeDev project [ "src/Triangle.elm" ]
4038

41-
test _ = do
42-
let project = "/Users/martinstewart/Documents/GitHub/compiler/test/scenario-webgl-extensions/"
43-
actual <- catchOutput $ Lamdera.Compile.makeDev project [ "src/Triangle.elm" ]
44-
45-
expectTextContains actual
46-
"Success! Compiled 1 module."
47-
in
48-
using setup cleanup test
39+
expectTextContains actual "Success! Compiled 1 module."
4940
]

0 commit comments

Comments
 (0)