---
cases:
  - data: {}
    modules:
      - |
        package generated

        p[[k, x]] {
          __local0__ = data.generated.q
          walk(__local0__, [k, x])
          __local1__ = k[1]
          contains(__local1__, "oo")
        }

        q = [{
          "foo": 1,
          "bar": 2,
          "bazoo": 3,
        }]
    note: walkbuiltin/match and filter
    query: data.generated.p = x
    sort_bindings: true
    want_result:
      - x:
          - - - 0
              - bazoo
            - 3
          - - - 0
              - foo
            - 1
