Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jdx committed Dec 14, 2023
1 parent 0374a91 commit 553d926
Showing 1 changed file with 18 additions and 18 deletions.
36 changes: 18 additions & 18 deletions src/cli/trust.rs
Original file line number Diff line number Diff line change
Expand Up @@ -37,27 +37,27 @@ impl Trust {
}
}
fn untrust(&self) -> Result<()> {
let path = match &self.config_file {
Some(filename) => PathBuf::from(filename),
None => match self.get_next_trusted() {
Some(path) => path,
None => bail!("No trusted config files found."),
},
};
config_file::untrust(&path)?;
rtxprintln!("untrusted {}", &path.canonicalize()?.display());
let path = match &self.config_file {
Some(filename) => PathBuf::from(filename),
None => match self.get_next_trusted() {
Some(path) => path,
None => bail!("No trusted config files found."),

Check warning on line 44 in src/cli/trust.rs

View check run for this annotation

Codecov / codecov/patch

src/cli/trust.rs#L38-L44

Added lines #L38 - L44 were not covered by tests
},
};
config_file::untrust(&path)?;
rtxprintln!("untrusted {}", &path.canonicalize()?.display());

Check warning on line 48 in src/cli/trust.rs

View check run for this annotation

Codecov / codecov/patch

src/cli/trust.rs#L47-L48

Added lines #L47 - L48 were not covered by tests
Ok(())
}
fn trust(&self) -> Result<()> {
let path = match &self.config_file {
Some(filename) => PathBuf::from(filename),
None => match self.get_next_untrusted() {
Some(path) => path,
None => bail!("No untrusted config files found."),
},
};
config_file::trust(&path)?;
rtxprintln!("trusted {}", &path.canonicalize()?.display());
let path = match &self.config_file {
Some(filename) => PathBuf::from(filename),
None => match self.get_next_untrusted() {
Some(path) => path,
None => bail!("No untrusted config files found."),

Check warning on line 56 in src/cli/trust.rs

View check run for this annotation

Codecov / codecov/patch

src/cli/trust.rs#L51-L56

Added lines #L51 - L56 were not covered by tests
},
};
config_file::trust(&path)?;
rtxprintln!("trusted {}", &path.canonicalize()?.display());
Ok(())
}

Check warning on line 62 in src/cli/trust.rs

View check run for this annotation

Codecov / codecov/patch

src/cli/trust.rs#L59-L62

Added lines #L59 - L62 were not covered by tests

Expand Down

0 comments on commit 553d926

Please sign in to comment.