mirror of
https://github.com/watchexec/watchexec.git
synced 2024-09-28 22:21:33 +02:00
Add more unix shell testing
This commit is contained in:
parent
52284ae866
commit
5da11d2fd7
@ -534,10 +534,25 @@ mod tests {
|
||||
use super::spawn;
|
||||
|
||||
#[test]
|
||||
fn test_start() {
|
||||
fn test_shell_default() {
|
||||
let _ = spawn(&["echo".into(), "hi".into()], &[], Shell::default(), false);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_shell_none() {
|
||||
let _ = spawn(&["echo".into(), "hi".into()], &[], Shell::None, false);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_shell_alternate() {
|
||||
let _ = spawn(
|
||||
&["echo".into(), "hi".into()],
|
||||
&[],
|
||||
Shell::Unix("bash".into()),
|
||||
false,
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn longest_common_path_should_return_correct_value() {
|
||||
let single_path = vec![PathBuf::from("/tmp/random/")];
|
||||
@ -614,22 +629,22 @@ mod tests {
|
||||
use super::{spawn, Shell};
|
||||
|
||||
#[test]
|
||||
fn test_default() {
|
||||
fn test_shell_default() {
|
||||
let _ = spawn(&["echo".into(), "hi".into()], &[], Shell::default(), false);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_cmd() {
|
||||
fn test_shell_cmd() {
|
||||
let _ = spawn(&["echo".into(), "hi".into()], &[], Shell::Cmd, false);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_powershell() {
|
||||
fn test_shell_powershell() {
|
||||
let _ = spawn(&["echo".into(), "hi".into()], &[], Shell::Powershell, false);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_bash() {
|
||||
fn test_shell_bash() {
|
||||
let _ = spawn(
|
||||
&["echo".into(), "hi".into()],
|
||||
&[],
|
||||
|
Loading…
Reference in New Issue
Block a user