summary refs log tree commit diff stats
path: root/tests/js
diff options
context:
space:
mode:
authorAndreas Rumpf <rumpf_a@web.de>2018-08-13 12:51:31 +0200
committerAndreas Rumpf <rumpf_a@web.de>2018-08-13 12:51:31 +0200
commit9f31096870103e93b23e17c4a68aa7dcdcc7889e (patch)
treedec84983af52db50e194969ae9d32042b12cb424 /tests/js
parent81645deb871d1ff869c0c7b289d8a851ee3b4214 (diff)
downloadNim-9f31096870103e93b23e17c4a68aa7dcdcc7889e.tar.gz
make JS tests green
Diffstat (limited to 'tests/js')
-rw-r--r--tests/js/tclosures.nim2
-rw-r--r--tests/js/testobjs.nim2
-rw-r--r--tests/js/tjsffi.nim2
3 files changed, 3 insertions, 3 deletions
diff --git a/tests/js/tclosures.nim b/tests/js/tclosures.nim
index 67243c937..659c60092 100644
--- a/tests/js/tclosures.nim
+++ b/tests/js/tclosures.nim
@@ -48,4 +48,4 @@ for i in 1 .. 10:
 
 let results = runCallbacks()
 
-doAssert(expected == results)
+doAssert(expected == $results)
diff --git a/tests/js/testobjs.nim b/tests/js/testobjs.nim
index dd66825ec..78f0b4766 100644
--- a/tests/js/testobjs.nim
+++ b/tests/js/testobjs.nim
@@ -34,7 +34,7 @@ var
   recurse1 = Recurse[int](data: 1, next: recurse2)
 
 
-doAssert test.name == "Jorden"
+doAssert test.name == cstring"Jorden"
 doAssert knight.age == 19
 doAssert knight.item.price == 50
 doAssert recurse1.next.next.data == 3
diff --git a/tests/js/tjsffi.nim b/tests/js/tjsffi.nim
index 325ab6366..156ca89e3 100644
--- a/tests/js/tjsffi.nim
+++ b/tests/js/tjsffi.nim
@@ -64,7 +64,7 @@ block:
   proc test(): bool =
     let obj = newJsObject()
     obj.`?!$` = proc(x, y, z: int, t: cstring): cstring = t & $(x + y + z)
-    obj.`?!$`(1, 2, 3, "Result is: ").to(cstring) == "Result is: 6"
+    obj.`?!$`(1, 2, 3, "Result is: ").to(cstring) == cstring"Result is: 6"
   echo test()
 
 # Test JsObject []()