Skip to content

Add crash logger snapshot test - #62

Merged
LimiNode merged 7 commits into
mainfrom
codex/add-crash-logger-tests-in-c++
Sep 16, 2025
Merged

Add crash logger snapshot test#62
LimiNode merged 7 commits into
mainfrom
codex/add-crash-logger-tests-in-c++

Conversation

@LimiNode

Copy link
Copy Markdown
Owner

Summary

  • add a crash logger test that registers CrashLogger with a simple formatter and appends sample messages
  • stub _exit, trigger the crash handler directly, and assert that the crash log captures the buffered messages and marker on each platform

Testing

  • cmake -S . -B build (fails: TimeShield not found in container)

https://chatgpt.com/codex/tasks/task_e_68c8964781b8832cae81d47b9447d7eb

Add a crash logger test that stubs _exit, triggers the handler, and verifies the crash log snapshot.
Update the crash logger test to avoid std::filesystem so it builds under the C++11 standard, include the public utility headers before touching crash logger internals, and switch includes to the exported logit_cpp paths while using simple std::remove cleanup.
Adjust crash logger test to use exported include paths without duplicating the logit_cpp prefix.
Ensure the crash logger test pulls in configuration macros by including logit/config.hpp before other logit headers so compilation succeeds when the test is built on CI.
Move the LogIt entry header before the platform-specific block and rely on it to provide crash logger definitions while keeping the exit stub in place.
Include the platform exit headers before redefining _exit and give the stub C linkage so macOS and Windows builds use the correct symbol.
@LimiNode
LimiNode merged commit 0edcd0a into main Sep 16, 2025
10 checks passed
@LimiNode
LimiNode deleted the codex/add-crash-logger-tests-in-c++ branch September 20, 2025 05:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant