Skip to content

Commit

Permalink
Test(eff_cfg): Add coverage for --dry-run
Browse files Browse the repository at this point in the history
As part of #26.

Signed-off-by: Paul Mabileau <paulmabileau@hotmail.fr>
  • Loading branch information
PaulDance committed Dec 24, 2024
1 parent a32e68a commit b1e8d71
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions src/config/effective_config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,7 @@ mod tests {
ship_cmd: ShipArgs {
force: Some(false),
no_self: Some(true),
dry_run: Some(false),
binstall: Some(BinstallChoice::Always),
..Default::default()
}
Expand All @@ -185,6 +186,7 @@ mod tests {
EffectiveShipArgs {
force: false,
no_self: true,
dry_run: false,
binstall: BinstallChoice::Always,
..Default::default()
},
Expand All @@ -204,6 +206,7 @@ mod tests {
ShipArgs {
force: Some(false),
no_self: Some(true),
dry_run: Some(false),
binstall: Some(BinstallChoice::Auto),
..Default::default()
},
Expand All @@ -212,6 +215,7 @@ mod tests {
EffectiveShipArgs {
force: false,
no_self: true,
dry_run: false,
binstall: BinstallChoice::Auto,
..Default::default()
},
Expand All @@ -232,13 +236,15 @@ mod tests {
ShipArgs {
no_fail_fast: Some(true),
skip_check: Some(false),
dry_run: Some(true),
binstall: Some(BinstallChoice::Never),
..Default::default()
},
),
EffectiveShipArgs {
no_fail_fast: true,
skip_check: false,
dry_run: true,
binstall: BinstallChoice::Never,
..Default::default()
},
Expand All @@ -261,6 +267,7 @@ mod tests {
},
ShipArgs {
only_self: Some(true),
dry_run: Some(false),
binstall: Some(BinstallChoice::Always),
..Default::default()
},
Expand All @@ -276,6 +283,7 @@ mod tests {
no_fail_fast: true,
skip_check: false,
only_self: true,
dry_run: false,
binstall: BinstallChoice::Always,
..Default::default()
},
Expand All @@ -294,6 +302,7 @@ mod tests {
no_self: Some(false),
no_fail_fast: Some(true),
skip_check: Some(false),
dry_run: Some(false),
binstall: Some(BinstallChoice::Always),
..Default::default()
}
Expand All @@ -304,6 +313,7 @@ mod tests {
no_self: Some(true),
no_fail_fast: Some(true),
skip_check: Some(false),
dry_run: Some(true),
binstall: Some(BinstallChoice::Auto),
..Default::default()
},
Expand All @@ -314,6 +324,7 @@ mod tests {
no_self: true,
no_fail_fast: true,
skip_check: false,
dry_run: true,
binstall: BinstallChoice::Auto,
..Default::default()
},
Expand All @@ -333,6 +344,7 @@ mod tests {
no_self: Some(false),
no_fail_fast: Some(true),
skip_check: Some(false),
dry_run: Some(true),
binstall: Some(BinstallChoice::Always),
..Default::default()
},
Expand All @@ -341,6 +353,7 @@ mod tests {
no_self: Some(true),
no_fail_fast: Some(true),
skip_check: Some(false),
dry_run: Some(false),
binstall: Some(BinstallChoice::Never),
..Default::default()
},
Expand All @@ -350,6 +363,7 @@ mod tests {
no_self: true,
no_fail_fast: true,
skip_check: false,
dry_run: false,
binstall: BinstallChoice::Never,
..Default::default()
},
Expand All @@ -368,6 +382,7 @@ mod tests {
no_self: Some(false),
no_fail_fast: Some(true),
skip_check: Some(false),
dry_run: Some(false),
binstall: Some(BinstallChoice::Auto),
..Default::default()
}
Expand All @@ -379,6 +394,7 @@ mod tests {
no_self: Some(true),
no_fail_fast: Some(true),
skip_check: Some(false),
dry_run: Some(true),
binstall: Some(BinstallChoice::Never),
..Default::default()
},
Expand All @@ -388,6 +404,7 @@ mod tests {
no_self: true,
no_fail_fast: true,
skip_check: false,
dry_run: true,
binstall: BinstallChoice::Never,
..Default::default()
},
Expand All @@ -406,13 +423,15 @@ mod tests {
no_self: Some(false),
no_fail_fast: Some(true),
skip_check: Some(false),
dry_run: Some(false),
binstall: Some(BinstallChoice::Never),
..Default::default()
}
}),
},
ShipArgs {
only_self: Some(false),
dry_run: Some(true),
binstall: Some(BinstallChoice::Auto),
..Default::default()
},
Expand All @@ -422,6 +441,7 @@ mod tests {
no_fail_fast: Some(true),
skip_check: Some(false),
only_self: Some(true),
dry_run: Some(false),
binstall: Some(BinstallChoice::Always),
..Default::default()
},
Expand All @@ -432,6 +452,7 @@ mod tests {
no_fail_fast: true,
skip_check: false,
only_self: true,
dry_run: false,
binstall: BinstallChoice::Always,
..Default::default()
},
Expand Down

0 comments on commit b1e8d71

Please sign in to comment.