Skip to content

Commit

Permalink
fix: exclude custom_logger from transport test-suite (getsentry#968)
Browse files Browse the repository at this point in the history
  • Loading branch information
supervacuus authored Mar 25, 2024
1 parent 9f9436a commit fda905a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
5 changes: 5 additions & 0 deletions include/sentry.h
Original file line number Diff line number Diff line change
Expand Up @@ -1068,6 +1068,11 @@ typedef void (*sentry_logger_function_t)(
* Sets the sentry-native logger function.
*
* Used for logging debug events when the `debug` option is set to true.
*
* Note: Multiple threads may invoke your `func`. If you plan to mutate any data
* inside the `userdata` argument after initialization, you must ensure proper
* synchronization inside the logger function.
*
*/
SENTRY_API void sentry_options_set_logger(
sentry_options_t *opts, sentry_logger_function_t func, void *userdata);
Expand Down
3 changes: 3 additions & 0 deletions tests/test_unit.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ def test_unit(cmake, unittest):

@pytest.mark.skipif(not has_http, reason="tests need http transport")
def test_unit_transport(cmake, unittest):
if unittest in ["custom_logger"]:
pytest.skip("excluded from transport test-suite")

cwd = cmake(["sentry_test_unit"], {"SENTRY_BACKEND": "none"})
env = dict(os.environ)
run(cwd, "sentry_test_unit", ["--no-summary", unittest], check=True, env=env)

0 comments on commit fda905a

Please sign in to comment.