nushell/tests
Wind 1964dacaef
Raise error when using o>| pipe (#13323)
# Description
From the feedbacks from @amtoine , it's good to make nushell shows error
for `o>|` syntax.

# User-Facing Changes
## Before
```nushell
'foo' o>| print                                                                                                                                                                                                                     07/09/2024 06:44:23 AM
Error: nu::parser::parse_mismatch

  × Parse mismatch during operation.
   ╭─[entry #6:1:9]
 1 │ 'foo' o>| print
   ·         ┬
   ·         ╰── expected redirection target
```

## After
```nushell
'foo' o>| print                                                                                                                                                                                                                     07/09/2024 06:47:26 AM
Error: nu::parser::parse_mismatch

  × Parse mismatch during operation.
   ╭─[entry #1:1:7]
 1 │ 'foo' o>| print
   ·       ─┬─
   ·        ╰── expected `|`.  Redirection stdout to pipe is the same as piping directly.
   ╰────
```

# Tests + Formatting
Added one test

---------

Co-authored-by: Darren Schroeder <343840+fdncred@users.noreply.github.com>
2024-07-09 07:11:25 -05:00
..
assets/nu_json Remove old nushell/merge engine-q 2022-02-07 14:54:06 -05:00
const_ add raw-string literal support (#9956) 2024-05-02 09:36:37 -04:00
eval Exit early when encountering parsing errors (#10213) 2023-09-05 14:36:37 +02:00
fixtures Force completers to sort in fetch() (#13242) 2024-07-03 06:48:06 -05:00
hooks Fix hooks on 0.92.0 (#12383) 2024-04-04 09:25:54 +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 Allow plugins to report their own version and store it in the registry (#12883) 2024-06-21 06:27:09 -05:00
plugins Use IntoValue and FromValue derive macros in nu_plugin_example for example usage (#13220) 2024-06-26 17:50:14 -05:00
repl remove the deprecated register command (#13297) 2024-07-05 07:16:50 -05:00
scope Avoid taking unnecessary ownership of intermediates (#12740) 2024-05-04 00:53:15 +00:00
shell Raise error when using o>| pipe (#13323) 2024-07-09 07:11:25 -05:00
main.rs Merged tests to produce a single binary (#12826) 2024-05-13 13:37:53 +00:00