Adds generic idetools api test case.
At the moment three lines of the test case fail in proc mode.
This commit is contained in:
parent
1d813167c4
commit
f11a3b2324
4 changed files with 70 additions and 1 deletions
23
tests/caas/idetools_api.nim
Normal file
23
tests/caas/idetools_api.nim
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
import unicode, sequtils
|
||||
|
||||
proc test_enums() =
|
||||
var o: Tfile
|
||||
if o.open("files " & "test.txt", fmWrite):
|
||||
o.write("test")
|
||||
o.close()
|
||||
|
||||
proc test_iterators(filename = "tests.nim") =
|
||||
let
|
||||
input = readFile(filename)
|
||||
letters = toSeq(runes(string(input)))
|
||||
for letter in letters: echo int(letter)
|
||||
|
||||
const SOME_SEQUENCE = @[1, 2]
|
||||
type
|
||||
bad_string = distinct string
|
||||
TPerson = object of TObject
|
||||
name*: bad_string
|
||||
age: int
|
||||
|
||||
proc adder(a, b: int): int =
|
||||
result = a + b
|
||||
Loading…
Add table
Add a link
Reference in a new issue