Skip to content

Commit

Permalink
Merge pull request #48 from timotheecour/pr_fix_outdir3
Browse files Browse the repository at this point in the history
fix outdir for windows (for good this time...)
  • Loading branch information
jangko authored Feb 13, 2020
2 parents 9434fa8 + 021c573 commit 73a5c1c
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions msgpack4nim.nimble
Original file line number Diff line number Diff line change
Expand Up @@ -12,20 +12,22 @@ installFiles = @["msgpack4nim.nim", "msgpack4collection.nim", "msgpack2any.nim",
# Examples and Tests
skipDirs = @["examples", "tests"]

template exec(cmd) =
echo cmd
system.exec(cmd)

task test, "Run all tests":
exec "nim c -r examples/test"
exec "nim c -r -d:msgpack_obj_to_map tests/test_any"
exec "nim c -r tests/test_json"
# because uses `getAppDir()`, see https://github.com/nim-lang/Nim/pull/13382
exec "nim c -r --outdir:tests tests/test_json"
exec "nim c -r tests/test_codec"
exec "nim c -r tests/test_spec"

exec "nim c -d:release -r examples/test"
exec "nim c -d:release -r -d:msgpack_obj_to_map tests/test_any"

# because uses `getAppDir()`, see https://github.com/nim-lang/Nim/pull/13382
exec "nim c -d:release tests/test_json"
when defined(windows): exec r"tests\test_json.exe"
else: exec r"tests/test_json"
# ditto
exec "nim c -d:release --outdir:tests tests/test_json"

exec "nim c -d:release -r tests/test_codec"
exec "nim c -d:release -r tests/test_spec"

0 comments on commit 73a5c1c

Please sign in to comment.