summaryrefslogtreecommitdiff
path: root/jstests/libs/change_stream_rewrite_util.js
diff options
context:
space:
mode:
authorLucas de Castro Borges <lucas@gnuabordo.com.br>2025-02-11 15:07:35 -0300
committerLucas de Castro Borges <lucas@gnuabordo.com.br>2025-02-11 15:07:35 -0300
commit4cb8841196d0625dfa3825aa326f071cd27c7b8b (patch)
tree1682a647d4463397c119183369ae6f750d5fdcff /jstests/libs/change_stream_rewrite_util.js
parentaa03c6362cbaa767638e6eed9b031d86dd2643d1 (diff)
parent8f0827553e09872941945a093b647a4211a9db7f (diff)
Update upstream source from tag 'upstream/6.0.0'master
Update to upstream version '6.0.0' with Debian dir 5604a80ec1c96ca76f25f40d78e6ef855abec322
Diffstat (limited to 'jstests/libs/change_stream_rewrite_util.js')
-rw-r--r--jstests/libs/change_stream_rewrite_util.js10
1 files changed, 2 insertions, 8 deletions
diff --git a/jstests/libs/change_stream_rewrite_util.js b/jstests/libs/change_stream_rewrite_util.js
index 918873c17bc..ebbb0937222 100644
--- a/jstests/libs/change_stream_rewrite_util.js
+++ b/jstests/libs/change_stream_rewrite_util.js
@@ -138,10 +138,7 @@ function assertNumMatchingOplogEventsForShard(stats, shardName, expectedTotalRet
assert(stats.shards.hasOwnProperty(shardName), stats);
assert.eq(Object.keys(stats.shards[shardName].stages[0])[0], "$cursor", stats);
const executionStats = stats.shards[shardName].stages[0].$cursor.executionStats;
- assert.eq(executionStats.nReturned,
- expectedTotalReturned,
- () => `Expected ${expectedTotalReturned} events on shard ${shardName} but got ` +
- `${executionStats.nReturned}. Execution stats:\n${tojson(executionStats)}`);
+ assert.eq(executionStats.nReturned, expectedTotalReturned, executionStats);
}
// Returns a newly created sharded collection sharded by caller provided shard key.
@@ -183,10 +180,7 @@ function verifyChangeStreamOnWholeCluster(
eventIdentifierList.forEach(eventIdentifier => {
assert.soon(() => cursor.hasNext(), {op: op, eventIdentifier: eventIdentifier});
const event = cursor.next();
- assert.eq(event.operationType,
- op,
- () => `Expected "${op}" but got "${event.operationType}". Full event: ` +
- `${tojson(event)}`);
+ assert.eq(event.operationType, op, event);
if (op == "dropDatabase") {
assert.eq(event.ns.db, eventIdentifier, event);