summaryrefslogtreecommitdiff
path: root/src/mongo/util/startup_test.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/util/startup_test.cpp')
-rw-r--r--src/mongo/util/startup_test.cpp36
1 files changed, 17 insertions, 19 deletions
diff --git a/src/mongo/util/startup_test.cpp b/src/mongo/util/startup_test.cpp
index 007ac9d5ad9..43f50f61755 100644
--- a/src/mongo/util/startup_test.cpp
+++ b/src/mongo/util/startup_test.cpp
@@ -31,29 +31,27 @@
#include "mongo/util/startup_test.h"
namespace mongo {
- std::vector<StartupTest*> *StartupTest::tests = 0;
- bool StartupTest::running = false;
+std::vector<StartupTest*>* StartupTest::tests = 0;
+bool StartupTest::running = false;
- StartupTest::StartupTest() {
- registerTest(this);
- }
-
- StartupTest::~StartupTest() {}
+StartupTest::StartupTest() {
+ registerTest(this);
+}
- void StartupTest::registerTest( StartupTest *t ) {
- if ( tests == 0 )
- tests = new std::vector<StartupTest*>();
- tests->push_back(t);
- }
+StartupTest::~StartupTest() {}
- void StartupTest::runTests() {
- running = true;
- for ( std::vector<StartupTest*>::const_iterator i = tests->begin();
- i != tests->end(); i++ ) {
+void StartupTest::registerTest(StartupTest* t) {
+ if (tests == 0)
+ tests = new std::vector<StartupTest*>();
+ tests->push_back(t);
+}
- (*i)->run();
- }
- running = false;
+void StartupTest::runTests() {
+ running = true;
+ for (std::vector<StartupTest*>::const_iterator i = tests->begin(); i != tests->end(); i++) {
+ (*i)->run();
}
+ running = false;
+}
} // namespace mongo