vmware-labs / yaml-jsonpath

JSONPath implementation for the gopkg.in/yaml.v3 node API
Other
49 stars 12 forks source link

Regression tests #51

Closed rjbaucells closed 10 months ago

rjbaucells commented 1 year ago

Updated latest regression tests document document and fixed failing tests.

There are two cases that I could not fix:

  - id: filter_expression_with_value_after_dot_notation_with_wildcard_on_array_of_objects
    selector: "$.*[?(@.key)]"
    document: [{"some": "some value"}, {"key": "value"}]
    consensus: []
    not-found-consensus: NOT_FOUND

Actual result:

[{"key": "value"}]
  - id: filter_expression_with_equals_on_object_with_key_matching_query
    selector: "$[?(@.id==2)]"
    document: {"id": 2}
    consensus: []
    not-found-consensus: NOT_FOUND

Actual result:

[{"id": 2}]

I used this library as a base to a Json implementation (see github.com/SteelBridgeLabs/jsonpath). All these fixes are based on updates I did on the Json library.

vmwclabot commented 1 year ago

@rjbaucells, you must sign our contributor license agreement before your changes are merged. Click here to sign the agreement. If you are a VMware employee, read this for further instruction.

vmwclabot commented 1 year ago

@rjbaucells, we have received your signed contributor license agreement. The review is usually completed within a week, but may take longer under certain circumstances. Another comment will be added to the pull request to notify you when the merge can proceed.

vmwclabot commented 1 year ago

@rjbaucells, VMware has approved your signed contributor license agreement.