Skip to content

Commit e8a3609

Browse files
committed
test all crash modes
1 parent eaf18c6 commit e8a3609

1 file changed

Lines changed: 5 additions & 3 deletions

File tree

tests/test_integration_native.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,8 @@ def test_native_wer_crash(cmake, httpserver, crash_arg):
117117

118118

119119
@pytest.mark.with_wer
120-
def test_native_wer_report(cmake, httpserver):
120+
@pytest.mark.parametrize("crash_mode", ["native", "minidump", "native-with-minidump"])
121+
def test_native_wer_report(cmake, httpserver, crash_mode):
121122
"""Test WER report capture with native backend"""
122123
tmp_path = cmake(["sentry_example"], {"SENTRY_BACKEND": "native"})
123124

@@ -127,14 +128,15 @@ def test_native_wer_report(cmake, httpserver):
127128
run_crash(
128129
tmp_path,
129130
"sentry_example",
130-
["log", "stdout", "crash", "attach-wer-report"],
131+
["log", "stdout", "crash", "crash-mode", crash_mode, "attach-wer-report"],
131132
env=dict(os.environ, SENTRY_DSN=make_dsn(httpserver)),
132133
)
133134
assert waiting.result
134135

135136
assert len(httpserver.log) >= 1
136137
envelope = Envelope.deserialize(httpserver.log[0][0].get_data())
137-
assert_native_crash(envelope)
138+
if "native" in crash_mode:
139+
assert_native_crash(envelope)
138140

139141
has_wer_report = any(
140142
item.headers.get("type") == "attachment"

0 commit comments

Comments
 (0)