nushell/crates/nu-cli/tests/commands
Jakub Žádník 8b597187fc
Path Command Enhancement Project (#2742)
* Add string argument support for path subcommands

* Add --replace option to 'path extension' command

* Add examples of replacing for path extension

* Refactor path extension and its example

* Add replacement functionality to path basename

* Refactor path subcommands to support more args

This adds a lot of redundancy to non-relevant subcommands such as type,
exists or expand.

* Add replace and num_levels options to path dirname

* Rename num_levels option to num-levels

* Remove commented code

* Clean up path basename

* Fix path dirname description

* Add path filestem opts; Rename extension -> suffix

* Add prefix option and examples to path filestem

* Fix broken num-levels of path dirname

* Fix failing example test of path filestem

* Fix failing test of path extension

* Formatting

* Add Windows-specific path subcommand examples

`path expand` is still broken but otherwise seems to fix all examples
on Windows

* Fix weird path expand on Windows

Also disable example tests for path expand. Failed caconicalization
(e.g., due to path not existing) returns the original path so the
examples always fail.

* Formatting

* Return path datatype when appropriate

* Do not append empty remainder to path dirname

* Add tests for path subcommands

* Formatting

* Revisit path subcommand description strings

* Apply clippy suggestions; Formatting

* Remove problematic test checking '~' expansion

Wouldn't run on minimal due to useing optional dependency.
The test success was also deending on the presence of home dir on the
testing machine which might not be completely robust.

* Add missing newline to file
2020-11-24 22:18:38 +13:00
..
keep Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
math Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
move_ Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
path Path Command Enhancement Project (#2742) 2020-11-24 22:18:38 +13:00
random Fix clippy lints (#2651) 2020-10-09 10:47:51 +13:00
skip Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
str_ Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
alias.rs Fix new clippy warnings (#2760) 2020-11-22 13:37:16 +13:00
append.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
autoenv_trust.rs Autoenv rewrite, security and scripting (#2083) 2020-07-06 05:34:00 +12:00
autoenv_untrust.rs Autoenv rewrite, security and scripting (#2083) 2020-07-06 05:34:00 +12:00
autoenv.rs Autoenv rewrite, security and scripting (#2083) 2020-07-06 05:34:00 +12:00
cal.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
cd.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
compact.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
count.rs Fix column count to not break on empty tables (#2374) 2020-08-18 22:16:35 -04:00
cp.rs When the nushell is located in a path that has a space in it, these tests break, this fixes it (#1944) 2020-06-07 15:50:52 +12:00
default.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
drop.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
each.rs Add in parameter inference for blocks (#2706) 2020-10-27 20:37:35 +13:00
echo.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
empty.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
enter.rs Convert open/fetch to stream (#2028) 2020-07-04 07:53:20 +12:00
every.rs Add 'every' command to select (or skip) every nth row (#1992) 2020-06-17 07:58:41 +12:00
first.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
flatten.rs Flatten rows containing same sub-table columns with distinct column names. (#2684) 2020-10-20 05:37:40 -05:00
format.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
get.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
group_by.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
headers.rs Pick->Select rename. Integration tests changes. (#1725) 2020-05-07 06:03:43 -05:00
histogram.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
insert.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
into_int.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
last.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
lines.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
ls.rs Inode added to ls -l (#2711) 2020-10-31 06:39:01 +13:00
merge.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
mkdir.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
mod.rs Path Command Enhancement Project (#2742) 2020-11-24 22:18:38 +13:00
nth.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
open.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
parse.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
prepend.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
range.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
reduce.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
rename.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
reverse.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
rm.rs remove without check path exist, rm -f (#2590) 2020-09-22 17:11:31 -04:00
save.rs Fix new clippy warnings (#2760) 2020-11-22 13:37:16 +13:00
select.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
semicolon.rs Pick->Select rename. Integration tests changes. (#1725) 2020-05-07 06:03:43 -05:00
sort_by.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
split_by.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
split_column.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
split_row.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
touch.rs touch: support multiple arguments (#2386) 2020-08-22 12:08:30 +12:00
uniq.rs Fix new clippy warnings (#2760) 2020-11-22 13:37:16 +13:00
update.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
where_.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00
with_env.rs Convert table of primitives to positional arguments for external cmd (#2232) 2020-07-23 09:41:34 +12:00
wrap.rs Remove it expansion (#2701) 2020-10-26 19:55:52 +13:00