diff options
author | may <may.hoque@mongodb.com> | 2017-07-18 13:00:00 -0400 |
---|---|---|
committer | may <may.hoque@mongodb.com> | 2017-07-18 13:01:11 -0400 |
commit | 6fb52b5c683765fecd681b0982334f01bb0776c1 (patch) | |
tree | 7346a7b5a2d5fa4cc93441bc7aae2a0eb9e07ed6 /src/mongo/db/repl/idempotency_test_fixture.h | |
parent | de836fca3ca8007a8b92fe8718f8b235cdb5b54c (diff) | |
download | mongo-6fb52b5c683765fecd681b0982334f01bb0776c1.tar.gz |
SERVER-29942 Introduce IdempotencyTest::testOpsAreIdempotent() to sync_tail_test to remove boilerplate
Diffstat (limited to 'src/mongo/db/repl/idempotency_test_fixture.h')
-rw-r--r-- | src/mongo/db/repl/idempotency_test_fixture.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/mongo/db/repl/idempotency_test_fixture.h b/src/mongo/db/repl/idempotency_test_fixture.h index 20cc7b574b1..9a53407b4bf 100644 --- a/src/mongo/db/repl/idempotency_test_fixture.h +++ b/src/mongo/db/repl/idempotency_test_fixture.h @@ -91,6 +91,11 @@ protected: } Status runOp(const OplogEntry& entry); Status runOps(std::initializer_list<OplogEntry> ops); + /** + * This method returns true if running the list of operations a single time is equivalent to + * running them two times. It returns false otherwise. + */ + void testOpsAreIdempotent(std::initializer_list<OplogEntry> ops); /** * Validate data and indexes. Return the MD5 hash of the documents ordered by _id. |