forked from qt-creator/qt-creator
ProjectExplorer: Fix setting up test terminator
When setting up the test terminator the used line parser has been setup already. Ensure the test terminator has the same search directories set up to avoid an assert. Change-Id: Ic881533f7735f769dd49d22860141c9213e77e09 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
@@ -111,7 +111,12 @@ void OutputParserTester::reset()
|
||||
|
||||
TestTerminator::TestTerminator(OutputParserTester *t) :
|
||||
m_tester(t)
|
||||
{ }
|
||||
{
|
||||
if (!t->lineParsers().isEmpty()) {
|
||||
for (const Utils::FilePath &searchDir : t->lineParsers().first()->searchDirectories())
|
||||
addSearchDir(searchDir);
|
||||
}
|
||||
}
|
||||
|
||||
Utils::OutputLineParser::Result TestTerminator::handleLine(const QString &line, Utils::OutputFormat type)
|
||||
{
|
||||
|
@@ -79,7 +79,7 @@ class TestTerminator : public OutputTaskParser
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
TestTerminator(OutputParserTester *t);
|
||||
explicit TestTerminator(OutputParserTester *t);
|
||||
|
||||
private:
|
||||
Result handleLine(const QString &line, Utils::OutputFormat type) override;
|
||||
|
Reference in New Issue
Block a user