forked from qt-creator/qt-creator
AutoTest: Add test frame work handling
Mainly a preparation for enabling/disabling test frame works. Change-Id: I0bbea7e055a607517ef8193587c229cadf0de027 Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
This commit is contained in:
@@ -26,6 +26,7 @@
|
||||
#include "autotestplugin.h"
|
||||
#include "autotestconstants.h"
|
||||
#include "testcodeparser.h"
|
||||
#include "testframeworkmanager.h"
|
||||
#include "testrunner.h"
|
||||
#include "testsettings.h"
|
||||
#include "testsettingspage.h"
|
||||
@@ -35,6 +36,10 @@
|
||||
#include "testresultspane.h"
|
||||
#include "testnavigationwidget.h"
|
||||
|
||||
#include "qtest/qttestframework.h"
|
||||
#include "quick/quicktestframework.h"
|
||||
#include "gtest/gtestframework.h"
|
||||
|
||||
#include <coreplugin/icore.h>
|
||||
#include <coreplugin/icontext.h>
|
||||
#include <coreplugin/actionmanager/actionmanager.h>
|
||||
@@ -73,11 +78,7 @@ AutotestPlugin::AutotestPlugin()
|
||||
|
||||
AutotestPlugin::~AutotestPlugin()
|
||||
{
|
||||
// Delete members
|
||||
TestTreeModel *model = TestTreeModel::instance();
|
||||
delete model;
|
||||
TestRunner *runner = TestRunner::instance();
|
||||
delete runner;
|
||||
delete m_frameworkManager;
|
||||
}
|
||||
|
||||
AutotestPlugin *AutotestPlugin::instance()
|
||||
@@ -129,6 +130,12 @@ bool AutotestPlugin::initialize(const QStringList &arguments, QString *errorStri
|
||||
|
||||
initializeMenuEntries();
|
||||
|
||||
m_frameworkManager = TestFrameworkManager::instance();
|
||||
m_frameworkManager->registerTestFramework(new QtTestFramework);
|
||||
m_frameworkManager->registerTestFramework(new QuickTestFramework);
|
||||
m_frameworkManager->registerTestFramework(new GTestFramework);
|
||||
TestTreeModel::instance()->syncTestFrameworks();
|
||||
|
||||
m_settings->fromSettings(ICore::settings());
|
||||
addAutoReleasedObject(new TestSettingsPage(m_settings));
|
||||
addAutoReleasedObject(new TestNavigationWidgetFactory);
|
||||
|
||||
Reference in New Issue
Block a user