oops, remove unnecessary -o
This commit is contained in:
parent
c2aeb5ac96
commit
43bc194f25
1 changed files with 5 additions and 2 deletions
|
@ -876,7 +876,7 @@ impl Display for Mount {
|
|||
write!(f, "mount")?;
|
||||
|
||||
if !self.options.is_empty() {
|
||||
write!(f, " -o {}", self.options)?;
|
||||
write!(f, " {}", self.options)?;
|
||||
}
|
||||
|
||||
write!(f, " {}", self.source)?;
|
||||
|
@ -1260,12 +1260,15 @@ mod tests {
|
|||
|
||||
#[test]
|
||||
fn mount_display() {
|
||||
let mnt = Mount::new(
|
||||
let mut mnt = Mount::new(
|
||||
DeviceId::Label("awawa".into()),
|
||||
"/mnt",
|
||||
MountOptions::default(),
|
||||
);
|
||||
|
||||
assert_eq!(mnt.to_string(), "mount LABEL=awawa /mnt");
|
||||
|
||||
mnt.options.push(MountOption::All);
|
||||
assert_eq!(mnt.to_string(), "mount --all LABEL=awawa /mnt");
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue