nvm/test
Oliver Henshaw 15eba7b7e6
[Fix] `nvm_strip_path`: Preserve leading/trailing colons
Path lists in environmental variables often give special meaning to
empty entries (e.g. in PATH or MANPATH). These are represented by
leading or trailing colons, or by doubled colons in the middle of the
list.

Adjust the awk invocation to correctly deal with trailing colons by
printing the separator before every field except the first, and then
printing the final separator that is read from the input - this will
either be a colon or the null string. This preserves leading and
trailing colons in all cases while not adding extra colons in the wrong
place.

Add test to confirm the correct behaviour.

Fixes #3144
2023-06-21 15:47:52 +01:00
..
fast [Fix] `nvm_strip_path`: Preserve leading/trailing colons 2023-06-21 15:47:52 +01:00
install_script [Tests] add some `nvm_do_install` tests 2022-12-27 22:57:07 -08:00
installation_iojs [Fix] `install`: Add missing io.js installation message 2019-01-22 15:46:29 +08:00
installation_node [Tests] move installation_node tests back to xenial 2022-12-22 16:16:10 -08:00
mocks [Fix] fix node download link for armv8l 2023-04-29 16:41:31 -07:00
slow [Tests] move tests that fail on focal to a separate suite that runs on xenial 2022-12-22 11:26:27 -08:00
sourcing [Tests] add test that fails without fix for #2362 2021-01-15 14:07:47 -08:00
xenial [Tests] move tests that fail on focal to a separate suite that runs on xenial 2022-12-22 11:26:27 -08:00
common.sh [Tests] add more checks to make_fake_* helpers 2019-02-23 15:24:02 -08:00