Details
-
Improvement
-
Resolution: Unresolved
-
Major - P3
-
None
-
None
-
None
-
None
-
Service Arch
Description
There are a number of tests and fixtures that set ClockSourceMock and/or TickSourceMock ad hoc:
|
Show all |
src/mongo/db/ftdc/ftdc_test.cpp
|
src/mongo/db/logical_clock_test_fixture.cpp
|
src/mongo/db/operation_context_test.cpp
|
src/mongo/db/repl/initial_syncer_test.cpp
|
src/mongo/db/repl/oplog_applier_impl_test.cpp
|
src/mongo/db/repl/replication_coordinator_test_fixture.cpp
|
src/mongo/db/s/migration_chunk_cloner_source_legacy_test.cpp
|
src/mongo/db/s/namespace_metadata_change_notifications_test.cpp
|
src/mongo/db/s/transaction_coordinator_test.cpp
|
src/mongo/db/s/vector_clock_config_server_test.cpp
|
src/mongo/db/s/vector_clock_shard_server_test.cpp
|
src/mongo/db/session_catalog_mongod_test.cpp
|
src/mongo/db/transaction_participant_test.cpp
|
src/mongo/db/vector_clock_mongod_test.cpp
|
src/mongo/dbtests/cursor_manager_test.cpp
|
src/mongo/dbtests/dbtests.cpp
|
src/mongo/s/catalog/replset_dist_lock_manager_test.cpp
|
src/mongo/s/commands/cluster_command_test_fixture.cpp
|
src/mongo/s/mongos_topology_coordinator_test.cpp
|
src/mongo/s/sharding_router_test_fixture.cpp
|
src/mongo/s/transaction_router_test.cpp
|
src/mongo/transport/service_state_machine_test.cpp
|
src/mongo/util/diagnostic_info_test.cpp
|
src/mongo/util/fail_point_test.cpp
|
src/mongo/util/future_util_test.cpp
|
When any time sources are set on the ServiceContext, they should all be set at once. When they are mocked, they should likely be set to the same underlying shared source. It is possible but not certain that tests should be utilizing features of the ServiceContextTest in some form to set clock sources in general. I suspect that we will find a few testing bugs if we do this work.
Attachments
Issue Links
- related to
-
SERVER-48650 Unit tests' ServiceContext's NetworkInterfaceMockClockSource cannot continue to depend upon the lifetime of the ReplicationCoordinator to remain valid
-
- Closed
-