Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
594 changes: 1 addition & 593 deletions test/common.py

Large diffs are not rendered by default.

611 changes: 611 additions & 0 deletions test/decorators.py

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion test/test_benchmark.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@
import clang_native
import common
import jsrun
from common import needs_make, read_binary, read_file, test_file
from common import read_binary, read_file, test_file
from decorators import needs_make

from tools import building, utils
from tools.shared import CLANG_CC, CLANG_CXX, EMCC, PIPE, config, run_process
Expand Down
20 changes: 11 additions & 9 deletions test/test_browser.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,32 +33,34 @@
HttpServerThread,
Reporting,
RunnerCore,
also_with_asan,
also_with_minimal_runtime,
also_with_wasm2js,
also_with_wasmfs,
copytree,
create_file,
disabled,
ensure_dir,
find_browser_test_file,
flaky,
has_browser,
is_chrome,
is_firefox,
is_safari,
path_from_root,
read_file,
test_file,
)
from decorators import (
also_with_asan,
also_with_minimal_runtime,
also_with_wasm2js,
also_with_wasmfs,
disabled,
flaky,
no_2gb,
no_4gb,
no_wasm64,
parameterize,
parameterized,
path_from_root,
read_file,
requires_dev_dependency,
requires_wasm2js,
skip_if,
skip_if_simple,
test_file,
with_all_sjlj,
)

Expand Down
3 changes: 1 addition & 2 deletions test/test_codesize.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,11 @@
RunnerCore,
compiler_for,
create_file,
node_pthreads,
parameterized,
read_binary,
read_file,
test_file,
)
from decorators import node_pthreads, parameterized

from tools import building, shared

Expand Down
16 changes: 9 additions & 7 deletions test/test_core.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,15 @@
PYTHON,
WEBIDL_BINDER,
RunnerCore,
compiler_for,
create_file,
env_modify,
path_from_root,
read_binary,
read_file,
test_file,
)
from decorators import (
all_engines,
also_with_minimal_runtime,
also_with_modularize,
Expand All @@ -36,11 +45,8 @@
also_with_wasmfs,
also_without_bigint,
can_do_standalone,
compiler_for,
create_file,
crossplatform,
disabled,
env_modify,
flaky,
is_slow_test,
needs_make,
Expand All @@ -51,9 +57,6 @@
node_pthreads,
parameterize,
parameterized,
path_from_root,
read_binary,
read_file,
requires_dev_dependency,
requires_jspi,
requires_native_clang,
Expand All @@ -63,7 +66,6 @@
requires_wasm2js,
requires_wasm_eh,
skip_if,
test_file,
with_all_eh_sjlj,
with_all_fs,
with_all_sjlj,
Expand Down
9 changes: 2 additions & 7 deletions test/test_interactive.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,8 @@
if __name__ == '__main__':
raise Exception('do not run this file directly; do something like: test/runner.py interactive')

from common import (
BrowserCore,
also_with_minimal_runtime,
create_file,
parameterized,
test_file,
)
from common import BrowserCore, create_file, test_file
from decorators import also_with_minimal_runtime, parameterized

from tools.shared import WINDOWS

Expand Down
9 changes: 2 additions & 7 deletions test/test_jslib.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,8 @@
import shutil
from subprocess import PIPE

from common import (
RunnerCore,
create_file,
parameterized,
read_file,
test_file,
)
from common import RunnerCore, create_file, read_file, test_file
from decorators import parameterized

from tools.shared import EMCC
from tools.utils import delete_file
Expand Down
16 changes: 9 additions & 7 deletions test/test_other.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,15 @@
TEST_ROOT,
WEBIDL_BINDER,
RunnerCore,
copytree,
create_file,
ensure_dir,
env_modify,
make_executable,
path_from_root,
test_file,
)
from decorators import (
all_engines,
also_with_asan,
also_with_minimal_runtime,
Expand All @@ -52,22 +61,16 @@
also_with_wasm64,
also_with_wasmfs,
also_without_bigint,
copytree,
create_file,
crossplatform,
disabled,
ensure_dir,
env_modify,
flaky,
is_slow_test,
make_executable,
no_mac,
no_windows,
node_pthreads,
only_windows,
parameterize,
parameterized,
path_from_root,
requires_dev_dependency,
requires_jspi,
requires_native_clang,
Expand All @@ -77,7 +80,6 @@
requires_v8,
requires_wasm64,
requires_wasm_eh,
test_file,
with_all_eh_sjlj,
with_all_fs,
with_all_sjlj,
Expand Down
3 changes: 2 additions & 1 deletion test/test_posixtest.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
import unittest

import test_posixtest_browser
from common import RunnerCore, node_pthreads, path_from_root
from common import RunnerCore, path_from_root
from decorators import node_pthreads

testsuite_root = path_from_root('test/third_party/posixtestsuite')

Expand Down
4 changes: 1 addition & 3 deletions test/test_sanity.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,15 +19,13 @@
EMBUILDER,
RunnerCore,
create_file,
crossplatform,
ensure_dir,
env_modify,
make_executable,
parameterized,
path_from_root,
test_file,
with_env_modify,
)
from decorators import crossplatform, parameterized, with_env_modify

from tools import cache, ports, response_file, shared, utils
from tools.config import EM_CONFIG
Expand Down
8 changes: 2 additions & 6 deletions test/test_sockets.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,11 @@

import clang_native
import common
from common import (
NON_ZERO,
PYTHON,
BrowserCore,
create_file,
from common import NON_ZERO, PYTHON, BrowserCore, create_file, read_file
from decorators import (
crossplatform,
no_windows,
parameterized,
read_file,
requires_dev_dependency,
requires_native_clang,
test_file,
Expand Down
9 changes: 2 additions & 7 deletions test/test_stress.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,8 @@
import subprocess
import threading

from common import (
NON_ZERO,
RunnerCore,
also_with_modularize,
is_slow_test,
node_pthreads,
)
from common import NON_ZERO, RunnerCore
from decorators import also_with_modularize, is_slow_test, node_pthreads


class stress(RunnerCore):
Expand Down