v0.6.0: strengthen backup integrity
This commit is contained in:
@@ -249,10 +249,10 @@ func TestSQLiteCreateIndexError(t *testing.T) {
|
||||
return nil, err
|
||||
}
|
||||
m.execFunc = func(query string, args ...any) (sql.Result, error) {
|
||||
callCount++
|
||||
if callCount == 2 {
|
||||
if strings.Contains(query, "CREATE INDEX") {
|
||||
return nil, fmt.Errorf("injected CREATE INDEX error")
|
||||
}
|
||||
callCount++
|
||||
return db.Exec(query, args...)
|
||||
}
|
||||
return db, nil
|
||||
|
||||
Reference in New Issue
Block a user