Skip to content

Commit

Permalink
pw_thread_stl: Disable tests failing on Windows
Browse files Browse the repository at this point in the history
Some pw_thread tests have a tendency to hang indefinitely on Windows,
likely due to MinGW-w64's pthread port not being thread-safe on Windows.
This change disables those tests until we can try them again using the
native Windows threading implementation.

Bug: b/317922402
Change-Id: I987b3e07c0758190f4c2b6a997f8c4dc069cc490
Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/186253
Commit-Queue: Auto-Submit <[email protected]>
Pigweed-Auto-Submit: Armando Montanez <[email protected]>
Reviewed-by: Erik Gilling <[email protected]>
  • Loading branch information
armandomontanez authored and CQ Bot Account committed Dec 28, 2023
1 parent 3cb7f0e commit ec98d2f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
5 changes: 4 additions & 1 deletion pw_thread/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,10 @@ pw_test_group("tests") {
}

pw_test("test_thread_context_facade_test") {
enable_if = pw_thread_TEST_THREAD_CONTEXT_BACKEND != ""
# TODO: b/317922402 - On Windows, this test can easily hang indefinitely.
# Disable on Windows until we can test with the native Windows SDK libraries
# for threading.
enable_if = pw_thread_TEST_THREAD_CONTEXT_BACKEND != "" && current_os != "win"
sources = [ "test_thread_context_facade_test.cc" ]
deps = [
":test_thread_context",
Expand Down
5 changes: 4 additions & 1 deletion pw_thread_stl/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -160,8 +160,11 @@ pw_source_set("non_portable_test_thread_options") {
}

pw_test("thread_backend_test") {
# TODO: b/317922402 - On Windows, this test can hang indefinitely. Disable on
# Windows until we can test with the native Windows SDK libraries for
# threading.
enable_if = pw_thread_THREAD_BACKEND == "$dir_pw_thread_stl:thread" &&
pw_thread_SLEEP_BACKEND != ""
pw_thread_SLEEP_BACKEND != "" && current_os != "win"
deps = [
":non_portable_test_thread_options",
"$dir_pw_thread:thread_facade_test",
Expand Down

0 comments on commit ec98d2f

Please sign in to comment.