diff options
author | Petr Mrázek <peterix@gmail.com> | 2018-08-02 01:01:55 +0200 |
---|---|---|
committer | Petr Mrázek <peterix@gmail.com> | 2018-08-02 01:01:55 +0200 |
commit | 5f2d3f014a255f35fd12e86c73c8152430851baf (patch) | |
tree | 0fb5d7f8920f1a3321ef2c5bc8db9064655fad9d /cmake/UnitTest | |
parent | 6aada8adf7df5075d5838512670a0b2cc2bc12a1 (diff) | |
download | MultiMC-5f2d3f014a255f35fd12e86c73c8152430851baf.tar MultiMC-5f2d3f014a255f35fd12e86c73c8152430851baf.tar.gz MultiMC-5f2d3f014a255f35fd12e86c73c8152430851baf.tar.lz MultiMC-5f2d3f014a255f35fd12e86c73c8152430851baf.tar.xz MultiMC-5f2d3f014a255f35fd12e86c73c8152430851baf.zip |
NOISSUE get rid of remaining tabs
Diffstat (limited to 'cmake/UnitTest')
-rw-r--r-- | cmake/UnitTest/TestUtil.h | 20 | ||||
-rw-r--r-- | cmake/UnitTest/generate_test_data.cmake | 30 |
2 files changed, 25 insertions, 25 deletions
diff --git a/cmake/UnitTest/TestUtil.h b/cmake/UnitTest/TestUtil.h index 84f18a2e..a478bdde 100644 --- a/cmake/UnitTest/TestUtil.h +++ b/cmake/UnitTest/TestUtil.h @@ -11,16 +11,16 @@ class TestsInternal { public: - static QByteArray readFile(const QString &fileName) - { - QFile f(fileName); - f.open(QFile::ReadOnly); - return f.readAll(); - } - static QString readFileUtf8(const QString &fileName) - { - return QString::fromUtf8(readFile(fileName)); - } + static QByteArray readFile(const QString &fileName) + { + QFile f(fileName); + f.open(QFile::ReadOnly); + return f.readAll(); + } + static QString readFileUtf8(const QString &fileName) + { + return QString::fromUtf8(readFile(fileName)); + } }; #define MULTIMC_GET_TEST_FILE(file) TestsInternal::readFile(QFINDTESTDATA(file)) diff --git a/cmake/UnitTest/generate_test_data.cmake b/cmake/UnitTest/generate_test_data.cmake index d9250fab..d0bd4ab1 100644 --- a/cmake/UnitTest/generate_test_data.cmake +++ b/cmake/UnitTest/generate_test_data.cmake @@ -2,22 +2,22 @@ # variables. Create destination directory if it does not exist. function(configure_files srcDir destDir) - make_directory(${destDir}) + make_directory(${destDir}) - file(GLOB templateFiles RELATIVE ${srcDir} ${srcDir}/*) - foreach(templateFile ${templateFiles}) - set(srcTemplatePath ${srcDir}/${templateFile}) - if(NOT IS_DIRECTORY ${srcTemplatePath}) - configure_file( - ${srcTemplatePath} - ${destDir}/${templateFile} - @ONLY - NEWLINE_STYLE LF - ) - else() - configure_files("${srcTemplatePath}" "${destDir}/${templateFile}") - endif() - endforeach() + file(GLOB templateFiles RELATIVE ${srcDir} ${srcDir}/*) + foreach(templateFile ${templateFiles}) + set(srcTemplatePath ${srcDir}/${templateFile}) + if(NOT IS_DIRECTORY ${srcTemplatePath}) + configure_file( + ${srcTemplatePath} + ${destDir}/${templateFile} + @ONLY + NEWLINE_STYLE LF + ) + else() + configure_files("${srcTemplatePath}" "${destDir}/${templateFile}") + endif() + endforeach() endfunction() configure_files(${SOURCE} ${DESTINATION})
\ No newline at end of file |