build: mark untestable function to be excluded from mutation tests
This commit is contained in:
parent
a09f95c019
commit
748cc15ea2
3 changed files with 4 additions and 0 deletions
|
@ -22,5 +22,7 @@ assert2 = "0.3"
|
|||
pretty_assertions = "1.4"
|
||||
rstest = "0.23"
|
||||
|
||||
mutants = "0.0"
|
||||
|
||||
[lints.rust]
|
||||
unexpected_cfgs = { level = "warn", check-cfg = ['cfg(tarpaulin_include)'] }
|
||||
|
|
|
@ -17,6 +17,7 @@ mod tests;
|
|||
|
||||
#[tokio::main]
|
||||
#[cfg(not(tarpaulin_include))]
|
||||
#[cfg_attr(test, mutants::skip)]
|
||||
async fn main() -> std::result::Result<(), Box<dyn std::error::Error>> {
|
||||
let github_workspace = std::env::var("GITHUB_WORKSPACE").context("GITHUB_WORKSPACE")?;
|
||||
let fs = kxio::fs::new(github_workspace);
|
||||
|
|
|
@ -6,6 +6,7 @@ pub trait Printer {
|
|||
pub struct StandardPrinter;
|
||||
impl Printer for StandardPrinter {
|
||||
#[cfg(not(tarpaulin_include))]
|
||||
#[cfg_attr(test, mutants::skip)]
|
||||
fn println(&self, message: impl Into<String>) {
|
||||
println!("{}", message.into());
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue