tests: mark more tests as fixed
parent
9278a0cfba
commit
77679d9650
|
@ -31,8 +31,6 @@ const (
|
||||||
|
|
||||||
'vlib/v/tests/live_test.v', // Linux & Solaris only; since live does not actually work for now with v2, just skip
|
'vlib/v/tests/live_test.v', // Linux & Solaris only; since live does not actually work for now with v2, just skip
|
||||||
'vlib/v/tests/asm_test.v', // skip everywhere for now, works on linux with cc != tcc
|
'vlib/v/tests/asm_test.v', // skip everywhere for now, works on linux with cc != tcc
|
||||||
'vlib/sqlite/sqlite_test.v', // works only on ubuntu with installed sqlite
|
|
||||||
'vlib/clipboard/clipboard_test.v', // needs code changes to make it compile with v2
|
|
||||||
]
|
]
|
||||||
skip_on_linux = []string
|
skip_on_linux = []string
|
||||||
skip_on_non_linux = []string
|
skip_on_non_linux = []string
|
||||||
|
|
|
@ -1,20 +1,23 @@
|
||||||
import sqlite
|
import sqlite
|
||||||
|
|
||||||
fn test_sqlite() {
|
fn test_sqlite() {
|
||||||
|
$if !linux {
|
||||||
|
return
|
||||||
|
}
|
||||||
db := sqlite.connect(':memory:')
|
db := sqlite.connect(':memory:')
|
||||||
db.exec("drop table if exists users")
|
db.exec("drop table if exists users")
|
||||||
db.exec("create table users (id integer primary key, name text default '');")
|
db.exec("create table users (id integer primary key, name text default '');")
|
||||||
|
|
||||||
db.exec("insert into users (name) values ('Sam')")
|
db.exec("insert into users (name) values ('Sam')")
|
||||||
db.exec("insert into users (name) values ('Peter')")
|
db.exec("insert into users (name) values ('Peter')")
|
||||||
db.exec("insert into users (name) values ('Kate')")
|
db.exec("insert into users (name) values ('Kate')")
|
||||||
|
|
||||||
nr_users := db.q_int('select count(*) from users')
|
nr_users := db.q_int('select count(*) from users')
|
||||||
assert nr_users == 3
|
assert nr_users == 3
|
||||||
|
|
||||||
name := db.q_string('select name from users where id = 1')
|
name := db.q_string('select name from users where id = 1')
|
||||||
assert name == 'Sam'
|
assert name == 'Sam'
|
||||||
|
|
||||||
users, mut code := db.exec('select * from users')
|
users, mut code := db.exec('select * from users')
|
||||||
assert users.len == 3
|
assert users.len == 3
|
||||||
assert code == 101
|
assert code == 101
|
||||||
|
|
|
@ -439,7 +439,7 @@ fn (mut g Gen) fn_decl(it ast.FnDecl) {
|
||||||
g.register_function_address(it.name)
|
g.register_function_address(it.name)
|
||||||
g.push(.rbp)
|
g.push(.rbp)
|
||||||
// g.write32(SEVENS)
|
// g.write32(SEVENS)
|
||||||
g.sub32(.rsp, 0x10)
|
// g.sub32(.rsp, 0x10)
|
||||||
}
|
}
|
||||||
for arg in it.args {
|
for arg in it.args {
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue