fix #14475; unittest.require now works with nim c; require and check now works with -d:nodejs (#14676)

* fix #14475; make unittest work with -d:nodejs

* fixup

* fixup

* disable inim, delaunay which failed after unittest.require got fixed

* re-enable tests that have been fixed
This commit is contained in:
Timothee Cour 2020-07-14 04:14:32 -07:00 • committed by GitHub
commit e07d661d16
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 55 additions and 13 deletions

View file

@ -5,7 +5,7 @@ just exiting...
joinable: false
"""
# Test the new beforeQuit variable:
# Test `addQuitProc`
proc myExit() {.noconv.} =
write(stdout, "just exiting...\n")

View file

@ -0,0 +1,22 @@
discard """
exitcode: 1
outputsub: "failed: 1 == 3"
matrix: "-d:case1; -d:case2"
targets: "c js"
joinable: false
"""
when defined case1:
import unittest
suite "Test":
test "test require":
check 1==2
check 1==3
when defined case2:
import unittest
suite "Test":
test "test require":
require 1 == 3
if true:
quit 0 # intentional