summary refs log tree commit diff stats
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rwxr-xr-xtests/tdllvar.nim16
-rwxr-xr-xtests/tindent1.nim24
2 files changed, 40 insertions, 0 deletions
diff --git a/tests/tdllvar.nim b/tests/tdllvar.nim
new file mode 100755
index 000000000..ab767770c
--- /dev/null
+++ b/tests/tdllvar.nim
@@ -0,0 +1,16 @@
+import os
+
+proc getDllName: string = 
+  result = "mylib.dll"
+  if ExistsFile(result): return
+  result = "mylib2.dll"
+  if ExistsFile(result): return
+  quit("could not load dynamic library")
+
+proc myImport(s: cstring) {.cdecl, importc, dynlib: getDllName().}
+proc myImport2(s: int) {.cdecl, importc, dynlib: getDllName().}
+
+myImport("test2")
+myImport2(12)
+
+
diff --git a/tests/tindent1.nim b/tests/tindent1.nim
new file mode 100755
index 000000000..0527b6e57
--- /dev/null
+++ b/tests/tindent1.nim
@@ -0,0 +1,24 @@
+
+const romanNumbers1 =
+    [
+    ("M", 1000), ("D", 500), ("C", 100),
+    ("L", 50), ("X", 10), ("V", 5), ("I", 1) ]
+
+const romanNumbers2 =
+    [
+    ("M", 1000), ("D", 500), ("C", 100),
+    ("L", 50), ("X", 10), ("V", 5), ("I", 1)
+    ]
+
+const romanNumbers3 =
+  [
+    ("M", 1000), ("D", 500), ("C", 100),
+    ("L", 50), ("X", 10), ("V", 5), ("I", 1)
+  ]
+
+const romanNumbers4 = [
+    ("M", 1000), ("D", 500), ("C", 100),
+    ("L", 50), ("X", 10), ("V", 5), ("I", 1)
+    ]
+
+