MCPcopy Create free account
hub / github.com/KDE/kdevelop / init

Method init

plugins/lldb/unittests/test_lldbformatters.cpp:126–144  ·  view source on GitHub ↗

Called before each testfunction is executed

Source from the content-addressed store, hash-verified

124
125// Called before each testfunction is executed
126void LldbFormattersTest::init()
127{
128 //remove all breakpoints - so we can set our own in the test
129 KConfigGroup bpCfg = KSharedConfig::openConfig()->group("breakpoints");
130 bpCfg.writeEntry("number", 0);
131 bpCfg.sync();
132
133 auto count = m_core->debugController()->breakpointModel()->rowCount();
134 m_core->debugController()->breakpointModel()->removeRows(0, count);
135
136 while (variableCollection()->watches()->childCount() > 0) {
137 auto idx = watchVariableIndexAt(0);
138 auto var = qobject_cast<LldbVariable*>(variableCollection()->itemForIndex(idx));
139 if (!var) break;
140 var->die();
141 }
142
143 m_session = new TestDebugSession;
144}
145
146void LldbFormattersTest::cleanup()
147{

Callers

nothing calls this directly

Calls 9

variableCollectionFunction · 0.85
writeEntryMethod · 0.80
debugControllerMethod · 0.80
rowCountMethod · 0.45
breakpointModelMethod · 0.45
removeRowsMethod · 0.45
childCountMethod · 0.45
itemForIndexMethod · 0.45
dieMethod · 0.45

Tested by

no test coverage detected