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

Function createFile

plugins/clang/tests/test_assistants.cpp:82–92  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

80}
81
82static QUrl createFile(const QString& fileContents, const QString& extension, int id)
83{
84 static QTemporaryDir tempDirA;
85 Q_ASSERT(tempDirA.isValid());
86 static QDir dirA(tempDirA.path());
87 QFile file(dirA.filePath(QString::number(id) + extension));
88 file.open(QIODevice::WriteOnly | QIODevice::Text);
89 file.write(fileContents.toUtf8());
90 file.close();
91 return QUrl::fromLocalFile(file.fileName());
92}
93
94class Testbed
95{

Callers 9

testMultiDotFilenamesMethod · 0.70
testActivationMethod · 0.70
testDisableBuddiesMethod · 0.70
testDisableAllMethod · 0.70
testMultipleFoldersMethod · 0.70
testSplitViewBuddiesMethod · 0.70
TestbedMethod · 0.70

Calls 7

isValidMethod · 0.45
pathMethod · 0.45
filePathMethod · 0.45
openMethod · 0.45
writeMethod · 0.45
closeMethod · 0.45
fileNameMethod · 0.45

Tested by

no test coverage detected