-
Couldn't load subscription status.
- Fork 35
Re-enable win tests #206
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Re-enable win tests #206
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
clang-tidy made some suggestions
| static bool exec(const char* cmd, std::vector<std::string>& outputs) { | ||
| #define DEBUG_TYPE "exec" | ||
|
|
||
| std::array<char, 256> buffer; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: 256 is a magic number; consider replacing it with a named constant [readability-magic-numbers]
std::array<char, 256> buffer;
^|
|
||
| std::string DetectResourceDir(const char* ClangBinaryName /* = clang */) { | ||
| std::string cmd = std::string(ClangBinaryName) + " -print-resource-dir"; | ||
| std::vector<std::string> outs; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: variable 'outs' is not initialized [cppcoreguidelines-init-variables]
| std::vector<std::string> outs; | |
| std::vector<std::string> outs = 0; |
| cmd += CompilerName; | ||
| cmd += " -xc++ -E -v /dev/null 2>&1 | sed -n -e '/^.include/,${' -e '/^ " | ||
| "\\/.*/p' -e '}'"; | ||
| std::vector<std::string> outs; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: variable 'outs' is not initialized [cppcoreguidelines-init-variables]
| std::vector<std::string> outs; | |
| std::vector<std::string> outs = 0; |
| #include "llvm/ADT/SmallString.h" | ||
| #include "llvm/Support/Path.h" | ||
|
|
||
| #include <gmock/gmock.h> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: 'gmock/gmock.h' file not found [clang-diagnostic-error]
#include <gmock/gmock.h>
^| #endif // LLVM_BINARY_DIR || !_WIN32 | ||
| Cpp::CreateInterpreter(); | ||
| EXPECT_STRNE(Cpp::DetectResourceDir().c_str(), Cpp::GetResourceDir()); | ||
| llvm::SmallString<256> Clang(LLVM_BINARY_DIR); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: 256 is a magic number; consider replacing it with a named constant [readability-magic-numbers]
llvm::SmallString<256> Clang(LLVM_BINARY_DIR);
^| #else | ||
| TEST(InterpreterTest, DetectSystemCompilerIncludePaths) { | ||
| #endif // _WIN32 | ||
| std::vector<std::string> includes; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: variable 'includes' is not initialized [cppcoreguidelines-init-variables]
| std::vector<std::string> includes; | |
| std::vector<std::string> includes = 0; |
af529fc to
1b6cda0
Compare
|
clang-tidy review says "All clean, LGTM! 👍" |
|
@vgvassilev I don't know exactly what is causing it to fail . The only thing I can tell from a quick glance is that it appears to have an issue with this line https://github.com/vgvassilev/CppInterOp/blob/1b6cda034fe805f3f9306b35737655631662e6dd/unittests/CMakeLists.txt#L44-L45 |
|
This PR can be closed since its been solved in #313 |
@mcbarton, @fsfod, do you have a clue why, although gtest is passing, on windows we get:
More here.