diff --git a/tests/unit/unittest/clangfixitoperationtest.cpp b/tests/unit/unittest/clangfixitoperationtest.cpp index 1ed3e86c937..7989b3c839c 100644 --- a/tests/unit/unittest/clangfixitoperationtest.cpp +++ b/tests/unit/unittest/clangfixitoperationtest.cpp @@ -82,11 +82,11 @@ protected: FixItContainer semicolonFixItContainer{Utf8StringLiteral(";"), {{filePath, 3u, 29u}, {filePath, 3u, 29u}}}; - QString semicolonErrorFile{QStringLiteral(TESTDATA_DIR"/diagnostic_semicolon_fixit.cpp")}; - QString semicolonExpectedFile{QStringLiteral(TESTDATA_DIR"/diagnostic_semicolon_fixit_expected.cpp")}; - QString compareWarningFile{QStringLiteral(TESTDATA_DIR"/diagnostic_comparison_fixit.cpp")}; - QString compareExpected1File{QStringLiteral(TESTDATA_DIR"/diagnostic_comparison_fixit_expected1.cpp")}; - QString compareExpected2File{QStringLiteral(TESTDATA_DIR"/diagnostic_comparison_fixit_expected2.cpp")}; + QString semicolonErrorFile{QString::fromUtf8(TESTDATA_DIR "/diagnostic_semicolon_fixit.cpp")}; + QString semicolonExpectedFile{QString::fromUtf8(TESTDATA_DIR"/diagnostic_semicolon_fixit_expected.cpp")}; + QString compareWarningFile{QString::fromUtf8(TESTDATA_DIR"/diagnostic_comparison_fixit.cpp")}; + QString compareExpected1File{QString::fromUtf8(TESTDATA_DIR"/diagnostic_comparison_fixit_expected1.cpp")}; + QString compareExpected2File{QString::fromUtf8(TESTDATA_DIR"/diagnostic_comparison_fixit_expected2.cpp")}; FixItContainer compareFixItContainer{Utf8StringLiteral("=="), {{filePath, 4u, 43u}, {filePath, 4u, 44u}}}; diff --git a/tests/unit/unittest/codecompletiontest.cpp b/tests/unit/unittest/codecompletiontest.cpp index 80679f7cd72..33a79d177be 100644 --- a/tests/unit/unittest/codecompletiontest.cpp +++ b/tests/unit/unittest/codecompletiontest.cpp @@ -118,7 +118,7 @@ Utf8String CodeCompleter::readFileContent(const QString &fileName) void CodeCompleter::copyTargetHeaderToTemporaryIncludeDirecory() { QFile::remove(targetHeaderPath); - bool hasCopied = QFile::copy(QStringLiteral(TESTDATA_DIR "/complete_target_header.h"), + bool hasCopied = QFile::copy(QString::fromUtf8(TESTDATA_DIR "/complete_target_header.h"), targetHeaderPath); EXPECT_TRUE(hasCopied); } @@ -126,7 +126,7 @@ void CodeCompleter::copyTargetHeaderToTemporaryIncludeDirecory() void CodeCompleter::copyChangedTargetHeaderToTemporaryIncludeDirecory() { QFile::remove(targetHeaderPath); - bool hasCopied = QFile::copy(QStringLiteral(TESTDATA_DIR "/complete_target_header_changed.h"), + bool hasCopied = QFile::copy(QString::fromUtf8(TESTDATA_DIR "/complete_target_header_changed.h"), targetHeaderPath); EXPECT_TRUE(hasCopied); }