Skip to content

Commit

Permalink
UT
Browse files Browse the repository at this point in the history
  • Loading branch information
plyhun committed Mar 12, 2024
1 parent 7f92113 commit f7370aa
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,7 @@ protected static Stream<List<Object>> queries() {
Arrays.asList("node-tag-query", true, false, "draft"),
Arrays.asList("nodes-query", true, false, "draft"),
Arrays.asList("nodes-query-by-uuids", true, false, "draft"),
Arrays.asList("nodes-query-by-uuids-common-filters", true, false, "draft"),
Arrays.asList("node-breadcrumb-query", true, false, "draft"),
Arrays.asList("node-breadcrumb-query-with-lang", true, false, "draft"),
Arrays.asList("node-language-fallback-query", true, false, "draft"),
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
{
orNodes: nodes( uuids: [ "43ee8f9ff71e4016ae8f9ff71e10161c", "4b1346a2163a4ff89346a2163a9ff883" ]
filter: {uuid: { or: [{equals: "43ee8f9ff71e4016ae8f9ff71e10161c"},{equals: "4b1346a2163a4ff89346a2163a9ff883"}] }}
) {
# [$.data.orNodes.totalCount=2]
totalCount

elements {
# [$.data.orNodes.elements[0].uuid=43ee8f9ff71e4016ae8f9ff71e10161c]
# [$.data.orNodes.elements[1].uuid=4b1346a2163a4ff89346a2163a9ff883]
uuid
}
}
oneOfNodes: nodes( uuids: [ "43ee8f9ff71e4016ae8f9ff71e10161c", "4b1346a2163a4ff89346a2163a9ff883" ]
filter: {uuid: { oneOf: ["43ee8f9ff71e4016ae8f9ff71e10161c", "4b1346a2163a4ff89346a2163a9ff883"] }}
) {
# [$.data.oneOfNodes.totalCount=2]
totalCount

elements {
# [$.data.oneOfNodes.elements[0].uuid=43ee8f9ff71e4016ae8f9ff71e10161c]
# [$.data.oneOfNodes.elements[1].uuid=4b1346a2163a4ff89346a2163a9ff883]
uuid
}
}
andNodes: nodes( uuids: [ "43ee8f9ff71e4016ae8f9ff71e10161c", "4b1346a2163a4ff89346a2163a9ff883" ]
filter: {uuid: { and: [{equals: "43ee8f9ff71e4016ae8f9ff71e10161c"},{equals: "4b1346a2163a4ff89346a2163a9ff883"}] }}
) {
# [$.data.andNodes.totalCount=0]
totalCount

elements {
uuid
}
}
notNodes: nodes( uuids: [ "43ee8f9ff71e4016ae8f9ff71e10161c", "4b1346a2163a4ff89346a2163a9ff883" ]
filter: {uuid: { not: {equals: "4b1346a2163a4ff89346a2163a9ff883"}}}
) {
# [$.data.notNodes.totalCount=1]
totalCount

elements {
# [$.data.notNodes.elements[0].uuid=43ee8f9ff71e4016ae8f9ff71e10161c]
uuid
}
}
}
# [$.errors=<is-undefined>]

0 comments on commit f7370aa

Please sign in to comment.