nushell/crates/nu-command/tests/commands
Andrew Barnes 319930a1b9
Add streaming support to save for ExternalStream data (#4985)
* Add streaming support to save for ExternalStream data

Prior to this change, save would collect data from an ExternalStream (data
originating from externals) consuming memory for the full amount of data piped
to it,

This change adds streaming support for ExternalStream allowing saving of
arbitrarily large files and bounding memory usage.

* Remove broken save test

This test passes but not for the right reasons, since this test was
written filename has become a required parameter.  The parser outputs
an error but the test still passes as is checking the original un-mutated
file assuming save has re-written the contents.

This change removes the test.

```
running 1 test
=== stderr
Error: nu::parser::missing_positional (https://docs.rs/nu-parser/0.60.0/nu-parser/enum.ParseError.html#variant.MissingPositional)

  × Missing required positional argument.
   ╭─[source:1:1]
 1 │ open save_test_1/cargo_sample.toml | save
   ·                                          ▲
   ·                                          ╰── missing filename
   ╰────
  help: Usage: save {flags} <filename>

test commands::save::figures_out_intelligently_where_to_write_out_with_metadata ... ok

test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 515 filtered out; finished in 0.10s
```
2022-03-27 15:39:27 +13:00
..
hash_ fix typo, update some examples and regenerate docs (#4718) 2022-03-04 06:10:09 -06:00
keep
math Fix operator precedence parser (#4947) 2022-03-25 16:23:08 +13:00
move_ fixed some more tests (#4607) 2022-02-22 11:32:29 -05:00
path Fix path join on streams (#4959) 2022-03-26 07:46:48 +13:00
random Another batch of command tests (#4496) 2022-02-16 07:38:02 -05:00
skip Strip trailing whitespace in files (#4575) 2022-02-21 08:38:15 -05:00
str_
alias.rs Allow expanding aliases before keywords, improve hiding (#4858) 2022-03-18 11:35:50 +13:00
all.rs
any.rs Strip trailing whitespace in files (#4575) 2022-02-21 08:38:15 -05:00
append.rs Strip trailing whitespace in files (#4575) 2022-02-21 08:38:15 -05:00
cal.rs
cd.rs
compact.rs
cp.rs
def.rs
default.rs
drop.rs fixed a couple more tests (#4870) 2022-03-18 12:35:28 -05:00
each.rs Simplify group/window into their own commands (#4760) 2022-03-06 20:01:29 -05:00
echo.rs Require block params (#4505) 2022-02-17 06:40:24 -05:00
empty.rs fix typo, update some examples and regenerate docs (#4718) 2022-03-04 06:10:09 -06:00
enter.rs
every.rs
find.rs
first.rs
flatten.rs fixed some more tests (#4607) 2022-02-22 11:32:29 -05:00
format.rs
get.rs a few more tests (#4488) 2022-02-15 20:48:32 -05:00
group_by.rs
headers.rs refactor: change column names from 'Column*' to 'column*' (#4556) 2022-02-19 19:26:47 -05:00
help.rs Remove old nushell/merge engine-q 2022-02-07 14:54:06 -05:00
histogram.rs
insert.rs Add insert/update to lists (#4873) 2022-03-19 10:12:54 +13:00
into_filesize.rs
into_int.rs
last.rs
length.rs Rename count to length (#3166) 2021-03-14 10:46:40 +13:00
lines.rs
ls.rs
merge.rs
mkdir.rs Rename count to length (#3166) 2021-03-14 10:46:40 +13:00
mod.rs Allow expanding aliases before keywords, improve hiding (#4858) 2022-03-18 11:35:50 +13:00
open.rs
parse.rs Add support for escape characters, make nuon a JSON superset (#4706) 2022-03-03 13:14:03 -05:00
prepend.rs Use 'table' on scripts and -c commands (#4377) 2022-02-09 05:58:54 -05:00
range.rs Use 'table' on scripts and -c commands (#4377) 2022-02-09 05:58:54 -05:00
reduce.rs Make reduce -n more sensible (#4791) 2022-03-09 05:56:08 -05:00
reject.rs Fix 4946 (#4951) 2022-03-25 20:48:01 +13:00
rename.rs Simplify empty?, improve default (#4797) 2022-03-09 08:46:28 -05:00
reverse.rs Remove old nushell/merge engine-q 2022-02-07 14:54:06 -05:00
rm.rs Fix single quote environment values (#4960) 2022-03-26 09:14:48 +13:00
roll.rs refactor: change column names from 'Column*' to 'column*' (#4556) 2022-02-19 19:26:47 -05:00
rotate.rs
run_external.rs Fix external extra (#4777) 2022-03-07 20:17:33 -05:00
save.rs Add streaming support to save for ExternalStream data (#4985) 2022-03-27 15:39:27 +13:00
select.rs
semicolon.rs
sort_by.rs fixed a couple more tests (#4870) 2022-03-18 12:35:28 -05:00
source.rs fixed a couple more tests (#4870) 2022-03-18 12:35:28 -05:00
split_by.rs Remove old nushell/merge engine-q 2022-02-07 14:54:06 -05:00
split_column.rs
split_row.rs Remove old nushell/merge engine-q 2022-02-07 14:54:06 -05:00
touch.rs
uniq.rs
update.rs Add insert/update to lists (#4873) 2022-03-19 10:12:54 +13:00
upsert.rs Add insert and update back (#4864) 2022-03-18 06:55:02 +13:00
use_.rs
where_.rs
which.rs Don't assume external ls (#4925) 2022-03-24 16:42:41 +13:00
with_env.rs
wrap.rs
zip.rs rename update to upsert to mirror what it really does (#4859) 2022-03-16 19:13:34 -05:00