forked from extern/nushell
29431e73c2
This commit changes the way we shell out externals when using the `"$it"` argument. Also pipes per row to an external's stdin if no `"$it"` argument is present for external commands. Further separation of logic (preparing the external's command arguments, getting the data for piping, emitting values, spawning processes) will give us a better idea for lower level details regarding external commands until we can find the right abstractions for making them more generic and unify within the pipeline calling logic of Nu internal's and external's.
18 lines
377 B
Rust
18 lines
377 B
Rust
use nu_test_support::{nu, pipeline};
|
|
|
|
#[test]
|
|
fn table_to_toml_text_and_from_toml_text_back_into_table() {
|
|
let actual = nu!(
|
|
cwd: "tests/fixtures/formats", pipeline(
|
|
r#"
|
|
open cargo_sample.toml
|
|
| to-toml
|
|
| from-toml
|
|
| get package.name
|
|
| echo $it
|
|
"#
|
|
));
|
|
|
|
assert_eq!(actual, "nu");
|
|
}
|