stop using old tempdir crate

This commit is contained in:
Scott Lamb
2021-05-17 13:08:01 -07:00
parent 13b497e243
commit 603f02b686
7 changed files with 30 additions and 61 deletions

View File

@@ -199,7 +199,9 @@ mod tests {
#[test]
fn upgrade_and_compare() -> Result<(), Error> {
testutil::init();
let tmpdir = tempdir::TempDir::new("moonfire-nvr-test")?;
let tmpdir = tempfile::Builder::new()
.prefix("moonfire-nvr-test")
.tempdir()?;
//let path = tmpdir.path().to_str().ok_or_else(|| format_err!("invalid UTF-8"))?.to_owned();
let mut upgraded = new_conn()?;
upgraded.execute_batch(include_str!("v0.sql"))?;