| 89 | } |
| 90 | |
| 91 | void TestGenerationTest::cppTemplate() |
| 92 | { |
| 93 | QString description = QStandardPaths::locate(QStandardPaths::GenericDataLocation, QStringLiteral("testgenerationtest/template_descriptions/test_qtestlib.desktop")); |
| 94 | QVERIFY(!description.isEmpty()); |
| 95 | SourceFileTemplate file; |
| 96 | file.addAdditionalSearchLocation(QStringLiteral(TESTS_DATA_DIR "/testgenerationtest/templates")); |
| 97 | file.setTemplateDescription(description); |
| 98 | |
| 99 | QCOMPARE(file.name(), QStringLiteral("Testing C++ Template")); |
| 100 | QVERIFY(file.isValid()); |
| 101 | |
| 102 | DocumentChangeSet changes = renderer->renderFileTemplate(file, baseUrl, urls(file)); |
| 103 | changes.applyAllChanges(); |
| 104 | |
| 105 | COMPARE_FILES("testname.h"); |
| 106 | COMPARE_FILES("testname.cpp"); |
| 107 | } |
| 108 | |
| 109 | QHash< QString, QUrl > TestGenerationTest::urls (const SourceFileTemplate& file) |
| 110 | { |
nothing calls this directly
no test coverage detected