Clean the DB data directory after the test is complete
()
| 545 | |
| 546 | // Clean the DB data directory after the test is complete |
| 547 | func (db *DB) Clean() { |
| 548 | if db != nil { |
| 549 | _ = db.Close() |
| 550 | err := os.RemoveAll(db.options.DirPath) |
| 551 | if err != nil { |
| 552 | panic(err) |
| 553 | } |
| 554 | } |
| 555 | } |