-
Notifications
You must be signed in to change notification settings - Fork 0
/
sqlbuilder.nimble
103 lines (67 loc) · 2.26 KB
/
sqlbuilder.nimble
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
# Package
version = "1.1.0"
author = "ThomasTJdev"
description = "SQL builder"
license = "MIT"
srcDir = "src"
# Dependencies
requires "nim >= 0.20.2"
when NimMajor >= 2:
requires "db_connector >= 0.1.0"
proc runLegacy() =
exec "nim c -d:dev -r tests/legacy_convert/test_legacy.nim"
exec "nim c -d:dev -r tests/legacy_convert/test_legacy_with_softdelete.nim"
exec "nim c -d:dev -r tests/legacy_convert/test_legacy_with_softdelete2.nim"
task testlegacy, "Test legacy":
runLegacy()
proc runSelect() =
exec "nim c -d:dev -r tests/select/test_select.nim"
exec "nim c -d:dev -r tests/select/test_select_arrays.nim"
exec "nim c -d:dev -r tests/select/test_select_is.nim"
exec "nim c -d:dev -r tests/select/test_select_deletemarker.nim"
exec "nim c -d:dev -r tests/select/test_select_const.nim"
exec "nim c -d:dev -r tests/select/test_select_const_deletemarker.nim"
exec "nim c -d:dev -r tests/select/test_select_const_where.nim"
task testselect, "Test select statement":
runSelect()
proc runInsert() =
exec "nim c -d:dev -r tests/insert/test_insert_db.nim"
exec "nim c -d:dev -r tests/insert/test_insert.nim"
task testinsert, "Test insert statement":
runInsert()
proc runUpdate() =
exec "nim c -d:dev -r tests/update/test_update.nim"
exec "nim c -d:dev -r tests/update/test_update_arrays.nim"
task testupdate, "Test update statement":
runUpdate()
proc runDelete() =
exec "nim c -d:dev -r tests/delete/test_delete.nim"
task testdelete, "Test delete statement":
runDelete()
proc runQueryCalls() =
exec "nim c -d:dev -r tests/query_calls/test_query_calls.nim"
task testquerycalls, "Test query calls":
runQueryCalls()
proc runToTypes() =
exec "nim c -d:dev -r tests/totypes/test_result_to_types.nim"
task testresulttotypes, "Test result to types":
runToTypes()
proc runArgs() =
exec "nim c -d:dev -r tests/custom_args/test_args.nim"
task testargs, "Test args":
runArgs()
proc runImport() =
exec "nim c -d:dev -r tests/importpackage/test_import1.nim"
exec "nim c -d:dev -r tests/importpackage/test_import2.nim"
task testimport, "Test import":
runImport()
task test, "Test":
runLegacy()
runSelect()
runInsert()
runUpdate()
runDelete()
runQueryCalls()
runToTypes()
runArgs()
runImport()