Bug 1616239 - Enable http3 tests for asan r=necko-reviewers,dragana

Differential Revision: https://phabricator.services.mozilla.com/D108635
This commit is contained in:
Kershaw Chang 2021-04-01 18:31:23 +00:00
Родитель 7c9741ae5d
Коммит 93423e9aa1
7 изменённых файлов: 77 добавлений и 30 удалений

Просмотреть файл

@ -23,6 +23,5 @@ features = ["gecko"]
[build-dependencies]
bindgen = {version = "0.56", default-features = false, features = ["runtime"] }
[[bin]]
name = "http3server"
path = "src/main.rs"
[lib]
crate-type = ["staticlib"]

Просмотреть файл

@ -0,0 +1,17 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include <stdio.h>
extern "C" {
void C_StartServer();
} // extern "C"
int main(int argc, char* argv[]) {
C_StartServer();
return 0;
}

Просмотреть файл

@ -0,0 +1,29 @@
# -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
# vim: set filetype=python:
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
if CONFIG["OS_ARCH"] == "WINNT":
OS_LIBS += [
"kernel32",
"userenv",
"wininet",
"ws2_32",
]
USE_LIBS += [
"http3server",
"nspr",
"nss",
]
GeckoSimplePrograms(
[
"http3server",
],
linkage=None,
)
if CONFIG["MOZ_ASAN"]:
LDFLAGS += ["-fsanitize=address"]

Просмотреть файл

@ -4,13 +4,7 @@
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
if (
CONFIG["COMPILE_ENVIRONMENT"]
and not CONFIG["MOZ_TSAN"]
and not CONFIG["MOZ_ASAN"]
and not CONFIG["FUZZING"]
and not CONFIG["OS_TARGET"] == "WINNT"
):
RUST_PROGRAMS += [
"http3server",
]
if CONFIG["OS_TARGET"] != "WINNT":
DIRS += ["executable"]
RustLibrary("http3server")

Просмотреть файл

@ -589,7 +589,7 @@ impl ServersRunner {
}
}
fn main() -> Result<(), io::Error> {
pub fn start_server() -> Result<(), io::Error> {
let args: Vec<String> = env::args().collect();
if args.len() < 2 {
eprintln!("Wrong arguments.");
@ -618,3 +618,8 @@ fn main() -> Result<(), io::Error> {
servers_runner.init();
servers_runner.run()
}
#[no_mangle]
pub extern "C" fn C_StartServer() {
start_server().expect("Server should be started succeed");
}

Просмотреть файл

@ -429,16 +429,15 @@ skip-if = os == "android"
[test_disabled_ftp.js]
[test_cache_204_response.js]
[test_http3.js]
# asan - bug 1616239
# tsan - bug 1622845
# win - bug 1616238
# android - bug 1622901
# mac - bug 1669892
skip-if = asan || tsan || os == 'win' || os =='android' || os == 'mac'
skip-if = tsan || os == 'win' || os =='android' || os == 'mac'
[test_http3_421.js]
skip-if = asan || tsan || os == 'win' || os =='android'
skip-if = tsan || os == 'win' || os =='android'
[test_http3_perf.js]
skip-if = asan || tsan || os == 'win' || os =='android'
skip-if = tsan || os == 'win' || os =='android'
[test_node_execute.js]
[test_loadgroup_cancel.js]
[test_obs-fold.js]
@ -461,9 +460,9 @@ run-sequentially = node server exceptions dont replay well
[test_http_sfv.js]
[test_blob_channelname.js]
[test_altsvc_pref.js]
skip-if = asan || tsan || os == 'win' || os =='android'
skip-if = tsan || os == 'win' || os =='android'
[test_http3_alt_svc.js]
skip-if = asan || tsan || os == 'win' || os =='android'
skip-if = tsan || os == 'win' || os =='android'
[test_use_httpssvc.js]
skip-if = os == "android"
run-sequentially = node server exceptions dont replay well
@ -481,38 +480,37 @@ run-sequentially = node server exceptions dont replay well
skip-if = os == "android"
run-sequentially = node server exceptions dont replay well
[test_trr_https_fallback.js]
skip-if = asan || tsan || os == 'win' || os =='android'
skip-if = tsan || os == 'win' || os =='android'
run-sequentially = node server exceptions dont replay well
[test_http3_trans_close.js]
skip-if = asan || tsan || os == 'win' || os =='android'
skip-if = tsan || os == 'win' || os =='android'
[test_brotli_http.js]
[test_altsvc_http3.js]
skip-if =
true # Bug 1675008
asan
tsan
os == 'win'
os =='android'
[test_http3_fatal_stream_error.js]
skip-if = asan || tsan || os == 'win' || os =='android' || socketprocess_networking
skip-if = tsan || os == 'win' || os =='android' || socketprocess_networking
run-sequentially = node server exceptions dont replay well
[test_http3_large_post.js]
skip-if = asan || tsan || os == 'win' || os =='android'
skip-if = tsan || os == 'win' || os =='android'
[test_http3_error_before_connect.js]
skip-if = asan || tsan || os == 'win' || os =='android' || socketprocess_networking
skip-if = tsan || os == 'win' || os =='android' || socketprocess_networking
run-sequentially = node server exceptions dont replay well
[test_http3_server_not_existing.js]
skip-if = asan || tsan || os == 'win' || os =='android' || socketprocess_networking
skip-if = tsan || os == 'win' || os =='android' || socketprocess_networking
run-sequentially = node server exceptions dont replay well
[test_http3_fast_fallback.js]
skip-if = asan || tsan || os == 'win' || os =='android' || socketprocess_networking
skip-if = tsan || os == 'win' || os =='android' || socketprocess_networking
run-sequentially = node server exceptions dont replay well
[test_cookie_ipv6.js]
[test_httpssvc_retry_with_ech.js]
skip-if = asan || tsan || os == 'win' || os =='android'
skip-if = tsan || os == 'win' || os =='android'
run-sequentially = node server exceptions dont replay well
[test_httpssvc_retry_without_ech.js]
skip-if = asan || tsan || os == 'win' || os =='android'
skip-if = tsan || os == 'win' || os =='android'
run-sequentially = node server exceptions dont replay well
[test_httpssvc_https_upgrade.js]
[test_bug1683176.js]

Просмотреть файл

@ -261,6 +261,11 @@ def check_networking(target, binary):
raise RuntimeError("Could not parse llvm-objdump output?")
basename = os.path.basename(binary)
# libhttp3server is used for test only, so we can skip it.
if basename == "libhttp3server.a":
print("TEST-SKIP | check_networking | {}".format(basename))
return 0
if bad_occurences_names:
s = (
"TEST-UNEXPECTED-FAIL | check_networking | {} | Identified {} "