Skip to content

Commit

Permalink
A couple quick fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremy-rifkin committed May 5, 2024
1 parent da0aa4d commit b1e3179
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
4 changes: 3 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -581,6 +581,8 @@ endif()
# =============================================== Demo/test ===============================================

if(CPPTRACE_BUILD_TESTING)
enable_testing()
if(PROJECT_IS_TOP_LEVEL)
enable_testing()
endif()
add_subdirectory(test)
endif()
4 changes: 4 additions & 0 deletions test/unittest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,9 @@ CPPTRACE_FORCE_NO_INLINE void raw_trace_basic_precise() {

TEST(RawTrace, Basic) {
raw_trace_basic();
#ifndef _MSC_VER
raw_trace_basic_precise();
#endif
}

CPPTRACE_FORCE_NO_INLINE void raw_trace_multi_1(std::pair<cpptrace::frame_ptr, cpptrace::frame_ptr> parent) {
Expand Down Expand Up @@ -99,7 +101,9 @@ CPPTRACE_FORCE_NO_INLINE void raw_trace_multi_precise_top() {

TEST(RawTrace, MultipleCalls) {
raw_trace_multi_top();
#ifndef _MSC_VER
raw_trace_multi_precise_top();
#endif
}

CPPTRACE_FORCE_NO_INLINE void stacktrace_basic() {
Expand Down

0 comments on commit b1e3179

Please sign in to comment.