MCPcopy Create free account
hub / github.com/cutelyst/cutelyst / writeJsonFile

Method writeJsonFile

tests/testserver.cpp:61–69  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

59}
60
61void TestServer::writeJsonFile(const QString &fileName, const QJsonObject &data)
62{
63 QFile f{fileName};
64 QVERIFY(f.open(QIODeviceBase::WriteOnly | QIODeviceBase::Text));
65
66 const QJsonDocument json{data};
67
68 QVERIFY(f.write(json.toJson(QJsonDocument::Indented)) > 0);
69}
70
71void TestServer::initTestCase()
72{

Callers

nothing calls this directly

Calls 1

writeMethod · 0.80

Tested by

no test coverage detected