Fix broken ordering of args when parsing command with env vars. (#1841)

This commit is contained in:
Jason Gedge
2020-05-24 19:26:27 -04:00
committed by GitHub
parent 8a99d112fc
commit 005d76cf57
3 changed files with 17 additions and 1 deletions

View File

@ -19,3 +19,13 @@ fn with_env_shorthand() {
assert_eq!(actual.out, "BARRRR");
}
#[test]
fn shorthand_doesnt_reorder_arguments() {
let actual = nu!(
cwd: "tests/fixtures/formats",
"FOO=BARRRR nu --testbin cococo first second"
);
assert_eq!(actual.out, "firstsecond");
}