void setup() { // setup background sync instance _bgsync = new BackgroundSyncTest(); // setup tail _tailer = new replset::SyncTail(_bgsync); // setup theReplSet ReplSetTest *rst = new ReplSetTest(); rst->setSyncTail(_bgsync); delete theReplSet; theReplSet = rst; }
static void setup() { replSettings.replSet = "foo"; replSettings.oplogSize = 5 * 1024 * 1024; createOplog(); // setup background sync instance _bgsync = new BackgroundSyncTest(); // setup tail _tailer = new repl::SyncTail(_bgsync); // setup theReplSet ReplSetTest *rst = ReplSetTest::make(); rst->setSyncTail(_bgsync); delete repl::theReplSet; repl::theReplSet = rst; }