Skip to content

Commit 7d144d9

Browse files
Fixed deprecated Tempdir::into_path API
This API was causing a `clippy` error. Signed-off-by: Abhijit Gadgil <agadgil@progress.com>
1 parent 533f705 commit 7d144d9

3 files changed

Lines changed: 4 additions & 4 deletions

File tree

components/common/src/templating.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -433,7 +433,7 @@ mod test {
433433

434434
#[tokio::test]
435435
async fn render_package_install() {
436-
let root = TempDir::new().expect("create temp dir").into_path();
436+
let root = TempDir::new().expect("create temp dir").keep();
437437
env::set_var(fs::FS_ROOT_ENVVAR, &root);
438438
let pg_id = PackageIdent::new("testing", "test", Some("1.0.0"), Some("20170712000000"));
439439

components/common/src/templating/config.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1132,7 +1132,7 @@ mod test {
11321132

11331133
#[tokio::test]
11341134
async fn test_compile_recursive_config_dir() {
1135-
let root = TempDir::new().expect("create temp dir").into_path();
1135+
let root = TempDir::new().expect("create temp dir").keep();
11361136

11371137
// Setup a dummy package directory with a config file inside
11381138
// a directory structure

components/core/src/package/install.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1285,7 +1285,7 @@ mod test {
12851285
ignored\n");
12861286

12871287
let mut expected = BTreeMap::new();
1288-
let fs_root_path = fs_root.into_path();
1288+
let fs_root_path = fs_root.keep();
12891289
expected.insert("FOO".to_string(), "bar".to_string());
12901290
expected.insert("JAVA_HOME".to_string(), "/my/java/home".to_string());
12911291
expected.insert(
@@ -1339,7 +1339,7 @@ mod test {
13391339
"PATH=/should/be/ignored\nJAVA_HOME=/my/java/home\nFOO=bar\n");
13401340

13411341
let mut expected = BTreeMap::new();
1342-
let fs_root_path = fs_root.into_path();
1342+
let fs_root_path = fs_root.keep();
13431343
let mut paths = vec![fs::fs_rooted_path(&pkg_prefix_for(&pkg_install).join("bin"),
13441344
&fs_root_path),
13451345
fs::fs_rooted_path(&pkg_prefix_for(&other_pkg_install).join("sbin"),

0 commit comments

Comments
 (0)