nushell/crates/nu-command/tests
Reilly Wood d409171ba8
Change comparison operators to allow nulls (#8617)
Prior to this PR, the less/greater than operators (`<`, `>`, `<=`, `>=`)
would throw an error if either side was null. After this PR, these
operators return null if either side (or both) is null.

### Examples
```bash 
1 < 3       # true
1 < null    # null
null < 3    # null
null < null # null
```

### Motivation

JT [asked the C#
folks](https://discord.com/channels/601130461678272522/615329862395101194/1086137515053957140)
and this is apparently the approach they would choose for comparison
operators if they could start from scratch.

This PR makes `where` more convenient to use on jagged/missing data. For
example, we can now filter on columns that may not be present in every
row:
```
> [{foo: 123} {}] | where foo? > 10
╭───┬─────╮
│ # │ foo │
├───┼─────┤
│ 0 │ 123 │
╰───┴─────╯
```
2023-03-26 12:10:09 +13:00
..
commands Change comparison operators to allow nulls (#8617) 2023-03-26 12:10:09 +13:00
format_conversions FEATURE: add --raw. --tabs and --indent to to nuon as in to json (#8366) 2023-03-20 15:47:18 -05:00
main.rs Expand Nushell's help system (#7611) 2022-12-30 17:44:37 +02:00