buildscripts/resmoke.py run --suites=aggregation --mongodSetParameters="{internalQueryEnableSlotBasedExecutionEngine: true}" --additionalFeatureFlags=featureFlagTimeseriesCollection,featureFlagSbePlanCache,featureFlagSBEGroupPushdown jstests/aggregation/sources/unionWith/unionWith.js
|
The failed test case:
// Test that a $group within a $unionWith sub-pipeline correctly fails if it needs to spill but
|
// 'allowDiskUse' is false.
|
assert.commandFailedWithCode(testDB.runCommand({
|
aggregate: collA.getName(),
|
pipeline: [
|
{
|
$unionWith: {
|
coll: collB.getName(),
|
pipeline: [
|
{"$group": {_id: "$groupKey", val: {$sum: "$val"}}},
|
{"$addFields": {groupKey: 1}}
|
]
|
}
|
},
|
],
|
allowDiskUse: false,
|
cursor: {}
|
}),
|
ErrorCodes.QueryExceededMemoryLimitNoDiskUseAllowed);
|
|