Commit 749e97db authored by Leandro Melo's avatar Leandro Melo
Browse files

Fixing unit test due to change in the Highlighter's constructor.

parent 6793f1f9
......@@ -47,9 +47,8 @@ char *toString(const QTextCharFormat &format)
using namespace TextEditor;
using namespace Internal;
HighlighterMock::HighlighterMock(const QSharedPointer<Context> &defaultContext,
QTextDocument *parent) :
Highlighter(defaultContext, parent),
HighlighterMock::HighlighterMock(QTextDocument *parent) :
Highlighter(parent),
m_debugDetails(false),
m_statesCounter(0),
m_formatsCounter(0),
......
......@@ -61,8 +61,7 @@ struct HighlightSequence
class HighlighterMock : public TextEditor::Internal::Highlighter
{
public:
HighlighterMock(const QSharedPointer<TextEditor::Internal::Context> &defaultContext,
QTextDocument *parent = 0);
HighlighterMock(QTextDocument *parent = 0);
void reset();
void showDebugDetails();
......
......@@ -122,7 +122,8 @@ void tst_HighlighterEngine::initTestCase()
createContexts();
createItemDatas();
m_highlighterMock.reset(new HighlighterMock(m_definition->initialContext()));
m_highlighterMock.reset(new HighlighterMock());
m_highlighterMock->setDefaultContext(m_definition->initialContext());
m_highlighterMock->setDocument(m_text.document());
m_highlighterMock->configureFormat(Highlighter::Keyword, Formats::instance().keywordFormat());
m_highlighterMock->configureFormat(Highlighter::DataType, Formats::instance().dataTypeFormat());
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment