nushell/tests
Wind 0a2fb137af
don't run subcommand if it's surrounded with backtick quote (#14210)
# Description
Fixes: #14202
After looking into the issue, I think #13910 it's not good to cut the
span if it's in external argument.
This pr is somehow revert the change, and fix
https://github.com/nushell/nushell/issues/13431 in another way.

It introduce a new state named `State::BackTickQuote`, so if an external
arg include backtick quote, it enters the state, so backtick quote won't
be the body of a string.

# User-Facing Changes
### Before
```nushell
> ^echo `(echo aa)`
aa
> ^echo `"aa"`   # maybe it's not right to remove the inner quote.
aa
```
### After
```nushell
> ^echo `(echo aa)`
(echo aa)
> ^echo `"aa"`    # inner quote is keeped if there are backtick quote outside.
"aa"
```

# Tests + Formatting
Added 3 tests.
2024-10-31 16:13:05 +01:00
..
assets/nu_json Remove old nushell/merge engine-q 2022-02-07 14:54:06 -05:00
const_ use command: Don't create a variable with empty record if it doesn't define any constants (#14051) 2024-10-20 23:12:57 +02:00
eval Fix try: Add set_last_error() to prepare_error_handler() for IR eval (#13838) 2024-09-13 00:07:22 -07:00
fixtures Fix LSP non-ascii characters offset issues. (#14002) 2024-10-29 06:35:37 -05:00
hooks Refactor config updates (#13802) 2024-10-11 18:40:32 +02:00
modules Enable reloading changes to a submodule (#13170) 2024-06-25 18:33:37 -07:00
overlays Avoid taking unnecessary ownership of intermediates (#12740) 2024-05-04 00:53:15 +00:00
parsing Avoid taking unnecessary ownership of intermediates (#12740) 2024-05-04 00:53:15 +00:00
path Avoid taking unnecessary ownership of intermediates (#12740) 2024-05-04 00:53:15 +00:00
plugin_persistence Make plugin list read state from plugin registry file as well (#14085) 2024-10-20 23:12:57 +02:00
plugins Make plugin list read state from plugin registry file as well (#14085) 2024-10-20 23:12:57 +02:00
repl error when closure param lists aren't terminated by | (#14095) 2024-10-22 10:40:45 -05:00
scope Change the usage misnomer to "description" (#13598) 2024-08-22 12:02:08 +02:00
shell don't run subcommand if it's surrounded with backtick quote (#14210) 2024-10-31 16:13:05 +01:00
main.rs Merged tests to produce a single binary (#12826) 2024-05-13 13:37:53 +00:00