Revert "Throw out error if external command in subexpression is failed to run (#8204)" (#8475)

This reverts commit dec0a2517f.

It breaks programs like `fzf`

# Description

Fixes: #8472 
Fixes:  #8313
Reopen: #7690 

# User-Facing Changes

_(List of all changes that impact the user experience here. This helps
us keep track of breaking changes.)_

# Tests + Formatting

Don't forget to add tests that cover your changes.

Make sure you've run and fixed any issues with these commands:

- `cargo fmt --all -- --check` to check standard code formatting (`cargo
fmt --all` applies these changes)
- `cargo clippy --workspace -- -D warnings -D clippy::unwrap_used -A
clippy::needless_collect` to check that you're using the standard code
style
- `cargo test --workspace` to check that all tests pass

> **Note**
> from `nushell` you can also use the `toolkit` as follows
> ```bash
> use toolkit.nu # or use an `env_change` hook to activate it
automatically
> toolkit check pr
> ```

# After Submitting

If your PR had any user-facing changes, update [the
documentation](https://github.com/nushell/nushell.github.io) after the
PR is merged, if necessary. This will help us keep the docs up to date.
This commit is contained in:
WindSoilder
2023-03-17 02:07:32 +08:00
committed by GitHub
parent 222c0f11c3
commit 31d9c0889c
3 changed files with 19 additions and 126 deletions

View File

@ -139,17 +139,6 @@ fn failed_command_with_semicolon_will_not_execute_following_cmds() {
})
}
#[test]
fn semicolon_works_within_subcommand() {
Playground::setup("external failed command with semicolon", |dirs, _| {
let actual = nu!(
cwd: dirs.test(), pipeline(r#"(nu --testbin outcome_err "aa"; echo done)"#
));
assert!(!actual.out.contains("done"));
})
}
#[cfg(not(windows))]
#[test]
fn external_args_with_quoted() {