refs #879, moved testdata into small files

motivated by MS comment
This commit is contained in:
Klaus Basan
2017-02-14 20:04:45 +01:00
committed by Mathew Sutcliffe
parent 368b955c66
commit a57b83f9de
13 changed files with 279 additions and 9 deletions

View File

@@ -264,6 +264,21 @@ namespace BlackConfig
return s;
}
QString getTestFilesDirImpl()
{
const QString d(CBuildConfig::getSwiftResourceDir());
if (d.isEmpty()) { return ""; }
const QDir dir(QDir::cleanPath(d + QDir::separator() + "test"));
Q_ASSERT_X(dir.exists(), Q_FUNC_INFO, "missing dir");
return dir.absolutePath();
}
const QString &CBuildConfig::getTestFilesDir()
{
static QString s(getTestFilesDirImpl());
return s;
}
const QString &CBuildConfig::getHtmlTemplateFileName()
{
static const QString s(getHtmlDir() + QDir::separator() + "swifttemplate.html");

View File

@@ -111,6 +111,9 @@ namespace BlackConfig
//! Where HTML files are located
static const QString &getHtmlDir();
//! Where test files are located
static const QString &getTestFilesDir();
//! Where HTML files are located
static const QString &getHtmlTemplateFileName();