Current Path: > > opt > cloudlinux > venv > lib > > python3.11 > site-packages > > numpy > distutils > tests
Operation : Linux premium131.web-hosting.com 4.18.0-553.44.1.lve.el8.x86_64 #1 SMP Thu Mar 13 14:29:12 UTC 2025 x86_64 Software : Apache Server IP : 162.0.232.56 | Your IP: 216.73.216.111 Domains : 1034 Domain(s) Permission : [ 0755 ]
Name | Type | Size | Last Modified | Actions |
---|---|---|---|---|
__pycache__ | Directory | - | - | |
__init__.py | File | 0 bytes | April 17 2025 13:10:58. | |
test_build_ext.py | File | 2769 bytes | April 17 2025 13:10:58. | |
test_ccompiler_opt.py | File | 28778 bytes | April 17 2025 13:10:58. | |
test_ccompiler_opt_conf.py | File | 6347 bytes | April 17 2025 13:10:58. | |
test_exec_command.py | File | 7395 bytes | April 17 2025 13:10:58. | |
test_fcompiler.py | File | 1277 bytes | April 17 2025 13:10:58. | |
test_fcompiler_gnu.py | File | 2136 bytes | April 17 2025 13:10:58. | |
test_fcompiler_intel.py | File | 1058 bytes | April 17 2025 13:10:58. | |
test_fcompiler_nagfor.py | File | 1102 bytes | April 17 2025 13:10:58. | |
test_from_template.py | File | 1103 bytes | April 17 2025 13:10:58. | |
test_log.py | File | 868 bytes | April 17 2025 13:10:58. | |
test_mingw32ccompiler.py | File | 1609 bytes | April 17 2025 13:10:58. | |
test_misc_util.py | File | 3218 bytes | April 17 2025 13:10:58. | |
test_npy_pkg_config.py | File | 2557 bytes | April 17 2025 13:10:58. | |
test_shell_utils.py | File | 2114 bytes | April 17 2025 13:10:58. | |
test_system_info.py | File | 10999 bytes | April 17 2025 13:10:58. |
import io import re from contextlib import redirect_stdout import pytest from numpy.distutils import log def setup_module(): f = io.StringIO() # changing verbosity also logs here, capture that with redirect_stdout(f): log.set_verbosity(2, force=True) # i.e. DEBUG def teardown_module(): log.set_verbosity(0, force=True) # the default r_ansi = re.compile(r"\x1B(?:[@-Z\\-_]|\[[0-?]*[ -/]*[@-~])") @pytest.mark.parametrize("func_name", ["error", "warn", "info", "debug"]) def test_log_prefix(func_name): func = getattr(log, func_name) msg = f"{func_name} message" f = io.StringIO() with redirect_stdout(f): func(msg) out = f.getvalue() assert out # sanity check clean_out = r_ansi.sub("", out) line = next(line for line in clean_out.splitlines()) assert line == f"{func_name.upper()}: {msg}"
SILENT KILLER Tool