Tempo ramps - make ramp test more challenging.
[ardour.git] / libs / ardour / test / testrunner.cc
index 4024490da0203cd1b118bc325869b4420bed32eb..ddb320e02b9058e60abd8bbc77f2f9e7b7b1f25d 100644 (file)
@@ -1,7 +1,9 @@
 #include <getopt.h>
+#include <glibmm/thread.h>
 
 #include <cppunit/CompilerOutputter.h>
 #include <cppunit/extensions/TestFactoryRegistry.h>
+#include <cppunit/extensions/HelperMacros.h>
 #include <cppunit/TestResult.h>
 #include <cppunit/TestResultCollector.h>
 #include <cppunit/TestRunner.h>
@@ -9,6 +11,9 @@
 
 #include "pbd/debug.h"
 #include "ardour/ardour.h"
+#include "test_ui.h"
+
+static const char* localedir = LOCALEDIR;
 
 int
 main(int argc, char* argv[])
@@ -44,22 +49,28 @@ main(int argc, char* argv[])
                }
        }
 
-       ARDOUR::init (false, false);
-       
+       CPPUNIT_ASSERT (ARDOUR::init (false, true, localedir));
+
+       TestUI* test_ui = new TestUI();
+
        CppUnit::TestResult testresult;
-       
+
        CppUnit::TestResultCollector collectedresults;
        testresult.addListener (&collectedresults);
-       
+
        CppUnit::BriefTestProgressListener progress;
        testresult.addListener (&progress);
-       
+
        CppUnit::TestRunner testrunner;
        testrunner.addTest (CppUnit::TestFactoryRegistry::getRegistry ().makeTest ());
        testrunner.run (testresult);
-       
+
        CppUnit::CompilerOutputter compileroutputter (&collectedresults, std::cerr);
        compileroutputter.write ();
-       
+
+       delete test_ui;
+
+       ARDOUR::cleanup ();
+
        return collectedresults.wasSuccessful () ? 0 : 1;
 }