From 7a8366fede5a2eeba56288d386bb5946a12995c4 Mon Sep 17 00:00:00 2001 From: Mitch Phillips Date: Mon, 11 Jul 2022 09:31:41 -0700 Subject: Extend bionic-unit-tests timeout. GWP-ASan stress tests can take a while, especially under HWASan. Bug: 238585984 Test: sleep(100) in one of the tests, and then 'atest bionic-unit-tests' Merged-In: Ibd983da1c8fd06cffed756cf3b24523f4671d49e Change-Id: Ibd983da1c8fd06cffed756cf3b24523f4671d49e (cherry picked from commit 1f3c8d688c8225dd725794562962d7726b590282) --- tests/gwp_asan_test.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/tests/gwp_asan_test.cpp b/tests/gwp_asan_test.cpp index b2c7780b1..23fb8b9b6 100644 --- a/tests/gwp_asan_test.cpp +++ b/tests/gwp_asan_test.cpp @@ -50,6 +50,15 @@ void RunGwpAsanTest(const char* test_name) { R"(\[ PASSED \] [1-9]+0? test)"); } +// GWP-ASan tests can run much slower, especially when combined with HWASan. +// Triple the deadline to avoid flakes (b/238585984). +extern "C" bool GetInitialArgs(const char*** args, size_t* num_args) { + static const char* initial_args[] = {"--deadline_threshold_ms=270000"}; + *args = initial_args; + *num_args = 1; + return true; +} + // This file implements "torture testing" under GWP-ASan, where we sample every // single allocation. The upper limit for the number of GWP-ASan allocations in // the torture mode is is generally 40,000, so that svelte devices don't -- cgit v1.2.3