Add a few simple integration tests

This commit is contained in:
2021-11-21 22:00:18 +01:00
parent ca1f649ecf
commit 78a957268d
5 changed files with 121 additions and 1 deletions

11
tests/helpers.rs Normal file
View File

@@ -0,0 +1,11 @@
use tempdir::TempDir;
pub fn init_tmpdir() -> TempDir {
let tmp_dir = TempDir::new("grm-test").unwrap();
println!("Temporary directory: {}", tmp_dir.path().display());
tmp_dir
}
pub fn cleanup_tmpdir(tempdir: TempDir) {
tempdir.close().unwrap();
}