init:store

This commit is contained in:
weisd
2024-06-28 11:09:20 +08:00
parent 3463fbec81
commit a9e515e5c0
3 changed files with 8 additions and 6 deletions
+3 -1
View File
@@ -375,6 +375,8 @@ pub enum DiskError {
impl DiskError {
pub fn check_disk_fatal_errs(errs: &Vec<Option<Error>>) -> Result<(), Error> {
println!("errs: {:?}", errs);
if Self::count_errs(errs, &DiskError::UnsupportedDisk) == errs.len() {
return Err(Error::new(DiskError::UnsupportedDisk));
}
@@ -412,7 +414,7 @@ impl DiskError {
return cast == err;
}
}
true
false
})
.count();
}
+1 -4
View File
@@ -624,10 +624,7 @@ mod test {
fn test_create_server_endpoints() {
let cases = vec![(
":9000",
vec![
// "/Users/weisd/fs".to_string(),
"http://localhost:900{1...2}/export{1...64}".to_string(),
],
vec!["http://localhost:900{1...2}/export{1...64}".to_string()],
)];
for (addr, args) in cases {
+4 -1
View File
@@ -1,5 +1,8 @@
#!/bin/bash
DATA_DIR="/tmp"
mkdir -p ./target/volume/test{0..4}
DATA_DIR="./target/volume/test{0...4}"
if [ -n "$1" ]; then
DATA_DIR="$1"