Eval external command result immediately when using do command with -c (#6645)

* make capture error works better in do command

* remove into string test because we have no way to generate Value::Error for now
This commit is contained in:
WindSoilder
2022-09-30 20:14:02 +08:00
committed by GitHub
parent 6f59167960
commit 530ff3893e
3 changed files with 108 additions and 17 deletions

View File

@ -172,18 +172,6 @@ fn from_nothing() {
assert_eq!(actual.out, "");
}
#[test]
fn from_error() {
let actual = nu!(
cwd: ".", pipeline(
r#"
do -c {$env.use} | into string
"#
));
assert_eq!(actual.out, "nu::shell::column_not_found");
}
#[test]
fn int_into_string() {
let actual = nu!(