Adjustments
This commit is contained in:
BIN
example/example
BIN
example/example
Binary file not shown.
@@ -15,7 +15,7 @@ func main() {
|
||||
flag.StringVar(&email, "email", "", "Email address to use for registration test")
|
||||
flag.Parse()
|
||||
|
||||
db, err:=sqlx.Open("sqlite3", ":memory")
|
||||
db, err:=sqlx.Open("sqlite3", ":memory:")
|
||||
if err!=nil {
|
||||
fmt.Println("Couldn't open sqlite3 in-memory db:" + err.Error())
|
||||
os.Exit(1)
|
||||
@@ -27,11 +27,13 @@ func main() {
|
||||
os.Exit(1)
|
||||
}
|
||||
schema:=`CREATE TABLE test_auth (
|
||||
username text NOT NULL unique key ,
|
||||
crypt text NOT NULL,
|
||||
email text NOT NULL unique key,
|
||||
username text NOT NULL ,
|
||||
password text NOT NULL,
|
||||
email text NOT NULL unique,
|
||||
recovery text NOT NULL DEFAULT '',
|
||||
recoverytime timestamp null,
|
||||
registration_date timestamp not null,
|
||||
registration_ip text not null,
|
||||
lastseen timestamp );`
|
||||
_ ,err=db.Exec(schema)
|
||||
if err != nil {
|
||||
|
Reference in New Issue
Block a user