MCPcopy
hub / github.com/mongodb/node-mongodb-native / transitionTopology

Function transitionTopology

test/unit/sdam/topology.test.ts:366–377  ·  view source on GitHub ↗
(topology, from, to)

Source from the content-addressed store, hash-verified

364 });
365
366 function transitionTopology(topology, from, to) {
367 topology.emit(
368 Topology.TOPOLOGY_DESCRIPTION_CHANGED,
369 new TopologyDescriptionChangedEvent(
370 2,
371 new TopologyDescription(from),
372 new TopologyDescription(to)
373 )
374 );
375 // We don't want the SrvPoller to actually run
376 clearTimeout(topology.s.srvPoller._timeout);
377 }
378
379 describe('srvRecordDiscovery event listener', function () {
380 beforeEach(() => {

Callers 1

topology.test.tsFile · 0.85

Calls 1

emitMethod · 0.65

Tested by

no test coverage detected