Skip to content

Commit 1fee572

Browse files
committed
chore(deps): Update Rust dependencies
Signed-off-by: Rene Leonhardt <65483435+reneleonhardt@users.noreply.github.com>
1 parent 422c397 commit 1fee572

File tree

3 files changed

+28
-17
lines changed

3 files changed

+28
-17
lines changed

.github/dependabot.yaml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ version: 2
22

33
updates:
44
- package-ecosystem: "docker"
5-
directory: "/"
5+
directory: "/.release"
66
labels: ["dependencies"]
77
schedule:
88
# By default, this will be on a Monday.
@@ -39,3 +39,13 @@ updates:
3939
go:
4040
patterns:
4141
- "*"
42+
43+
- package-ecosystem: "cargo"
44+
directory: "/functional-tests"
45+
labels: ["area/CI"]
46+
schedule:
47+
interval: "weekly"
48+
groups:
49+
ci:
50+
patterns:
51+
- "*"

functional-tests/Cargo.toml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@ edition = "2021"
55
authors = ["Adrian Utrilla <adrianutrilla@gmail.com>"]
66

77
[dependencies]
8-
tempdir = "0.3.5"
8+
tempfile = "3"
99
serde = "1.0"
10-
serde_json = "1.0.99"
11-
serde_yaml = "0.9.22"
10+
serde_json = "1.0"
11+
serde_yaml = "0.9"
1212
serde_derive = "1.0"
13-
lazy_static = "1.4.0"
13+
lazy_static = "1.5"

functional-tests/src/lib.rs

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
1+
#[cfg_attr(test, macro_use)]
2+
extern crate lazy_static;
13
extern crate serde;
24
extern crate serde_json;
35
extern crate serde_yaml;
4-
extern crate tempdir;
5-
#[macro_use]
6-
extern crate lazy_static;
7-
#[macro_use]
8-
extern crate serde_derive;
6+
extern crate tempfile;
97

108
#[cfg(test)]
119
mod tests {
@@ -19,7 +17,8 @@ mod tests {
1917
use std::io::{Read, Write};
2018
use std::path::Path;
2119
use std::process::Command;
22-
use tempdir::TempDir;
20+
use tempfile::Builder;
21+
use tempfile::TempDir;
2322
const SOPS_BINARY_PATH: &'static str = "./sops";
2423
const KMS_KEY: &'static str = "FUNCTIONAL_TEST_KMS_ARN";
2524

@@ -36,8 +35,10 @@ mod tests {
3635
}
3736

3837
lazy_static! {
39-
static ref TMP_DIR: TempDir =
40-
TempDir::new("sops-functional-tests").expect("Unable to create temporary directory");
38+
static ref TMP_DIR: TempDir = Builder::new()
39+
.prefix("sops-functional-tests")
40+
.tempdir()
41+
.expect("Unable to create temporary directory");
4142
}
4243

4344
fn prepare_temp_file(name: &str, contents: &[u8]) -> String {
@@ -806,7 +807,7 @@ b: ba"#
806807
let file_path = "res/comments.yaml";
807808
let output = Command::new(SOPS_BINARY_PATH)
808809
.arg("encrypt")
809-
.arg(file_path.clone())
810+
.arg(file_path)
810811
.output()
811812
.expect("Error running sops");
812813
assert!(output.status.success(), "SOPS didn't return successfully");
@@ -825,7 +826,7 @@ b: ba"#
825826
let file_path = "res/comments_list.yaml";
826827
let output = Command::new(SOPS_BINARY_PATH)
827828
.arg("encrypt")
828-
.arg(file_path.clone())
829+
.arg(file_path)
829830
.output()
830831
.expect("Error running sops");
831832
assert!(output.status.success(), "SOPS didn't return successfully");
@@ -844,7 +845,7 @@ b: ba"#
844845
let file_path = "res/comments.enc.yaml";
845846
let output = Command::new(SOPS_BINARY_PATH)
846847
.arg("decrypt")
847-
.arg(file_path.clone())
848+
.arg(file_path)
848849
.output()
849850
.expect("Error running sops");
850851
assert!(output.status.success(), "SOPS didn't return successfully");
@@ -863,7 +864,7 @@ b: ba"#
863864
let file_path = "res/comments_unencrypted_comments.yaml";
864865
let output = Command::new(SOPS_BINARY_PATH)
865866
.arg("decrypt")
866-
.arg(file_path.clone())
867+
.arg(file_path)
867868
.output()
868869
.expect("Error running sops");
869870
assert!(output.status.success(), "SOPS didn't return successfully");

0 commit comments

Comments
 (0)