projects
/
ostree.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
763d2d2
)
rust/tests: fix static delta generation testcase
author
Luca BRUNO
<luca.bruno@coreos.com>
Tue, 11 Oct 2022 09:03:40 +0000
(09:03 +0000)
committer
Luca BRUNO
<luca.bruno@coreos.com>
Thu, 13 Oct 2022 16:30:00 +0000
(16:30 +0000)
rust-bindings/tests/repo/generate_static.rs
patch
|
blob
|
history
diff --git
a/rust-bindings/tests/repo/generate_static.rs
b/rust-bindings/tests/repo/generate_static.rs
index b2f3cd74a3ac259801b7ec7bc7efb110f5cc372b..297ce95d3703f94a96a351832243f238a2756875 100644
(file)
--- a/
rust-bindings/tests/repo/generate_static.rs
+++ b/
rust-bindings/tests/repo/generate_static.rs
@@
-14,8
+14,10
@@
fn should_generate_static_delta_at() {
let delta_path = delta_dir.path().join("static_delta.file");
let path_var = delta_path
.to_str()
+ .map(std::ffi::CString::new)
.expect("no valid path")
- .as_bytes()
+ .unwrap()
+ .as_bytes_with_nul()
.to_variant();
let test_repo = TestRepo::new();
@@
-38,5
+40,5
@@
fn should_generate_static_delta_at() {
)
.expect("static delta generate");
- assert!(
std::fs::File::open(&delta_path).is_err
());
+ assert!(
delta_path.try_exists().unwrap
());
}