Skip to content

Commit

Permalink
Increase timeouts of 'restapi_return_codes-t' for ASAN builds
Browse files Browse the repository at this point in the history
  • Loading branch information
JavierJF committed May 16, 2024
1 parent f867451 commit 63968d6
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion test/tap/tests/reg_test_3223-restapi_return_codes-t.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ const vector<honest_req_t> honest_requests {
{ { "partial_output_flush_script", "%s.py", "POST", 10000 }, { "{}" } },
};

const vector<faulty_req_t> invalid_requests {
vector<faulty_req_t> invalid_requests {
// Checks that 'POST' fails for:
// 1 - Empty parameters.
// 2 - Invalid JSON input.
Expand Down Expand Up @@ -279,6 +279,14 @@ int main(int argc, char** argv) {

vector<ept_info_t> i_epts_info {};
const auto ext_i_epts_info = [] (const faulty_req_t& req) { return req.ept_info; };

int wasan = get_env_int("WITHASAN", 0);
if (wasan) {
for (auto& req : invalid_requests) {
req.ept_info.timeout += 2000;
}
}

std::transform(
invalid_requests.begin(), invalid_requests.end(), std::back_inserter(i_epts_info), ext_i_epts_info
);
Expand Down

0 comments on commit 63968d6

Please sign in to comment.