Get reliable tempfile names from ioutil.TempFile

Also makes them easier to spot (the tests tend to litter /tmp).
This commit is contained in:
Lars Buitinck
2015-06-05 16:02:14 +02:00
parent 542ae647f8
commit cebbf42ff6
2 changed files with 29 additions and 28 deletions

View File

@@ -12,7 +12,7 @@ import (
)
func TestFTS3(t *testing.T) {
tempFilename := TempFilename()
tempFilename := TempFilename(t)
db, err := sql.Open("sqlite3", tempFilename)
if err != nil {
t.Fatal("Failed to open database:", err)