-
Notifications
You must be signed in to change notification settings - Fork 455
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add a test for a new(?) example on $unionWith
add support for invoking without a collection name or type
- Loading branch information
1 parent
5de5268
commit 07830d9
Showing
8 changed files
with
82 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 3 additions & 0 deletions
3
core/src/test/resources/dev/morphia/test/aggregation/stages/unionWith/example3/data.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ _id: 1, flavor: "chocolate" }, | ||
{ _id: 2, flavor: "strawberry" }, | ||
{ _id: 3, flavor: "cherry" } |
5 changes: 5 additions & 0 deletions
5
core/src/test/resources/dev/morphia/test/aggregation/stages/unionWith/example3/expected.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ _id: 1, flavor: 'chocolate' }, | ||
{ _id: 2, flavor: 'strawberry' }, | ||
{ _id: 3, flavor: 'cherry' }, | ||
{ _id: 4, flavor: 'orange' }, | ||
{ _id: 5, flavor: 'vanilla', price: 20 } |
1 change: 1 addition & 0 deletions
1
core/src/test/resources/dev/morphia/test/aggregation/stages/unionWith/example3/name
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Create a Union with Specified Documents |
12 changes: 12 additions & 0 deletions
12
core/src/test/resources/dev/morphia/test/aggregation/stages/unionWith/example3/pipeline.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
{ | ||
$unionWith: { | ||
pipeline: [ | ||
{ | ||
$documents: [ | ||
{ _id: 4, flavor: "orange" }, | ||
{ _id: 5, flavor: "vanilla", price: 20 } | ||
] | ||
} | ||
] | ||
} | ||
} |