forked from extern/nushell
Add some cell path tests (#7563)
This commit is contained in:
@ -2,6 +2,18 @@ use nu_test_support::fs::Stub::FileWithContent;
|
||||
use nu_test_support::playground::Playground;
|
||||
use nu_test_support::{nu, pipeline};
|
||||
|
||||
#[test]
|
||||
fn simple_get_record() {
|
||||
let actual = nu!(r#"({foo: 'bar'} | get foo) == "bar""#);
|
||||
assert_eq!(actual.out, "true");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn simple_get_list() {
|
||||
let actual = nu!(r#"([{foo: 'bar'}] | get foo) == [bar]"#);
|
||||
assert_eq!(actual.out, "true");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn fetches_a_row() {
|
||||
Playground::setup("get_test_1", |dirs, sandbox| {
|
||||
|
Reference in New Issue
Block a user