From 2d237e7e8e5dd749b9399c7f98e3319cd5204523 Mon Sep 17 00:00:00 2001 From: Mike Farah Date: Sat, 11 Jan 2020 19:13:52 +1100 Subject: [PATCH] it works! wip --- commands_test.go | 2 +- examples/sample.yaml | 13 +++++++++---- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/commands_test.go b/commands_test.go index 370a0a97..d7cebecb 100644 --- a/commands_test.go +++ b/commands_test.go @@ -96,7 +96,7 @@ func TestReadCmd(t *testing.T) { func TestReadWithAdvancedFilterCmd(t *testing.T) { cmd := getRootCommand() - result := test.RunCmd(cmd, "read examples/sample.yaml b.e(name == sam).value") + result := test.RunCmd(cmd, "read -v examples/sample.yaml b.e(name==sam).value") if result.Error != nil { t.Error(result.Error) } diff --git a/examples/sample.yaml b/examples/sample.yaml index 603dc54d..1fb93352 100644 --- a/examples/sample.yaml +++ b/examples/sample.yaml @@ -1,4 +1,9 @@ -- name: fred - value: 3 -- name: sam - value: 4 \ No newline at end of file +a: true +b: + c: 2 + d: [3, 4, 5] + e: + - name: fred + value: 3 + - name: sam + value: 4 \ No newline at end of file