2222#include " filesettings.h"
2323#include " fixture.h"
2424#include " helpers.h"
25+ #include " path.h"
2526#include " settings.h"
2627#include " suppressions.h"
2728
@@ -116,7 +117,7 @@ class TestCppcheck : public TestFixture {
116117 Suppressions supprs;
117118 ErrorLogger2 errorLogger;
118119 CppCheck cppcheck (s, supprs, errorLogger, false , {});
119- ASSERT_EQUALS (1 , cppcheck.check (FileWithDetails (file.path ())));
120+ ASSERT_EQUALS (1 , cppcheck.check (FileWithDetails (file.path (), Path::identify (file. path (), false ), 0 )));
120121 // TODO: how to properly disable these warnings?
121122 errorLogger.ids .erase (std::remove_if (errorLogger.ids .begin (), errorLogger.ids .end (), [](const std::string& id) {
122123 return id == " logChecker" ;
@@ -138,7 +139,7 @@ class TestCppcheck : public TestFixture {
138139 Suppressions supprs;
139140 ErrorLogger2 errorLogger;
140141 CppCheck cppcheck (s, supprs, errorLogger, false , {});
141- FileSettings fs{file.path ()};
142+ FileSettings fs{file.path (), Path::identify (file. path (), false ), 0 };
142143 ASSERT_EQUALS (1 , cppcheck.check (fs));
143144 // TODO: how to properly disable these warnings?
144145 errorLogger.ids .erase (std::remove_if (errorLogger.ids .begin (), errorLogger.ids .end (), [](const std::string& id) {
@@ -162,7 +163,7 @@ class TestCppcheck : public TestFixture {
162163 Suppressions supprs;
163164 ErrorLogger2 errorLogger;
164165 CppCheck cppcheck (s, supprs, errorLogger, false , {});
165- ASSERT_EQUALS (0 , cppcheck.check (FileWithDetails (file.path ())));
166+ ASSERT_EQUALS (0 , cppcheck.check (FileWithDetails (file.path (), Path::identify (file. path (), false ), 0 )));
166167 // TODO: how to properly disable these warnings?
167168 errorLogger.ids .erase (std::remove_if (errorLogger.ids .begin (), errorLogger.ids .end (), [](const std::string& id) {
168169 return id == " logChecker" ;
@@ -188,8 +189,8 @@ class TestCppcheck : public TestFixture {
188189 Suppressions supprs;
189190 ErrorLogger2 errorLogger;
190191 CppCheck cppcheck (s, supprs, errorLogger, false , {});
191- ASSERT_EQUALS (1 , cppcheck.check (FileWithDetails (test_file_a.path ())));
192- ASSERT_EQUALS (1 , cppcheck.check (FileWithDetails (test_file_b.path ())));
192+ ASSERT_EQUALS (1 , cppcheck.check (FileWithDetails (test_file_a.path (), Path::identify (test_file_a. path (), false ), 0 )));
193+ ASSERT_EQUALS (1 , cppcheck.check (FileWithDetails (test_file_b.path (), Path::identify (test_file_b. path (), false ), 0 )));
193194 // TODO: how to properly disable these warnings?
194195 errorLogger.errmsgs .erase (std::remove_if (errorLogger.errmsgs .begin (), errorLogger.errmsgs .end (), [](const ErrorMessage& msg) {
195196 return msg.id == " logChecker" ;
@@ -220,7 +221,7 @@ class TestCppcheck : public TestFixture {
220221 Suppressions supprs;
221222 ErrorLogger2 errorLogger;
222223 CppCheck cppcheck (s, supprs, errorLogger, false , {});
223- ASSERT_EQUALS (1 , cppcheck.check (FileWithDetails (test_file.path ())));
224+ ASSERT_EQUALS (1 , cppcheck.check (FileWithDetails (test_file.path (), Path::identify (test_file. path (), false ), 0 )));
224225 // TODO: how to properly disable these warnings?
225226 errorLogger.errmsgs .erase (std::remove_if (errorLogger.errmsgs .begin (), errorLogger.errmsgs .end (), [](const ErrorMessage& msg) {
226227 return msg.id == " logChecker" ;
0 commit comments