Linux server1.dn-server.com 4.18.0-553.89.1.lve.el8.x86_64 #1 SMP Wed Dec 10 13:58:50 UTC 2025 x86_64
LiteSpeed
Server IP : 195.201.204.189 & Your IP : 216.73.216.198
Domains :
Cant Read [ /etc/named.conf ]
User : beriska1
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
opt /
alt /
python38 /
lib64 /
python3.8 /
test /
Delete
Unzip
Name
Size
Permission
Date
Action
__pycache__
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
audiodata
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
capath
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
cjkencodings
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
data
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
decimaltestdata
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
dtracedata
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
eintrdata
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
encoded_modules
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
imghdrdata
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
libregrtest
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
sndhdrdata
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
subprocessdata
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
support
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
test_asyncio
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
test_email
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
test_import
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
test_importlib
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
test_json
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
test_warnings
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
tracedmodules
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
xmltestdata
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
ziptestdata
[ DIR ]
drwxr-xr-x
2026-05-01 04:21
Sine-1000Hz-300ms.aif
60.25
KB
-rw-r--r--
2024-09-07 00:11
__init__.py
47
B
-rw-r--r--
2024-09-07 00:11
__main__.py
41
B
-rw-r--r--
2024-09-07 00:11
_test_multiprocessing.py
183.48
KB
-rw-r--r--
2024-09-07 00:11
allsans.pem
9.87
KB
-rw-r--r--
2024-09-07 00:11
ann_module.py
1.08
KB
-rw-r--r--
2024-09-07 00:11
ann_module2.py
519
B
-rw-r--r--
2024-09-07 00:11
ann_module3.py
448
B
-rw-r--r--
2024-09-07 00:11
audiotest.au
27.48
KB
-rw-r--r--
2024-09-07 00:11
audiotests.py
12.46
KB
-rw-r--r--
2024-09-07 00:11
audit-tests.py
9.08
KB
-rw-r--r--
2024-09-07 00:11
autotest.py
209
B
-rw-r--r--
2024-09-07 00:11
bad_coding.py
24
B
-rw-r--r--
2024-09-07 00:11
bad_coding2.py
30
B
-rw-r--r--
2024-09-07 00:11
bad_getattr.py
61
B
-rw-r--r--
2024-09-07 00:11
bad_getattr2.py
77
B
-rw-r--r--
2024-09-07 00:11
bad_getattr3.py
139
B
-rw-r--r--
2024-09-07 00:11
badcert.pem
1.88
KB
-rw-r--r--
2024-09-07 00:11
badkey.pem
2.11
KB
-rw-r--r--
2024-09-07 00:11
badsyntax_3131.py
32
B
-rw-r--r--
2024-09-07 00:11
badsyntax_future10.py
95
B
-rw-r--r--
2024-09-07 00:11
badsyntax_future3.py
172
B
-rw-r--r--
2024-09-07 00:11
badsyntax_future4.py
153
B
-rw-r--r--
2024-09-07 00:11
badsyntax_future5.py
184
B
-rw-r--r--
2024-09-07 00:11
badsyntax_future6.py
161
B
-rw-r--r--
2024-09-07 00:11
badsyntax_future7.py
196
B
-rw-r--r--
2024-09-07 00:11
badsyntax_future8.py
122
B
-rw-r--r--
2024-09-07 00:11
badsyntax_future9.py
142
B
-rw-r--r--
2024-09-07 00:11
badsyntax_pep3120.py
14
B
-rw-r--r--
2024-09-07 00:11
bisect_cmd.py
4.86
KB
-rwxr-xr-x
2024-09-07 00:11
bytecode_helper.py
1.56
KB
-rw-r--r--
2024-09-07 00:11
cfgparser.1
67
B
-rw-r--r--
2024-09-07 00:11
cfgparser.2
19.02
KB
-rw-r--r--
2024-09-07 00:11
cfgparser.3
1.55
KB
-rw-r--r--
2024-09-07 00:11
clinic.test
94.65
KB
-rw-r--r--
2024-09-07 00:11
cmath_testcases.txt
141.05
KB
-rw-r--r--
2024-09-07 00:11
coding20731.py
22
B
-rw-r--r--
2024-09-07 00:11
curses_tests.py
1.22
KB
-rwxr-xr-x
2024-09-07 00:11
dataclass_module_1.py
837
B
-rw-r--r--
2024-09-07 00:11
dataclass_module_1_str.py
835
B
-rw-r--r--
2024-09-07 00:11
dataclass_module_2.py
756
B
-rw-r--r--
2024-09-07 00:11
dataclass_module_2_str.py
754
B
-rw-r--r--
2024-09-07 00:11
dataclass_textanno.py
126
B
-rw-r--r--
2024-09-07 00:11
datetimetester.py
239.84
KB
-rw-r--r--
2024-09-07 00:11
dis_module.py
76
B
-rw-r--r--
2024-09-07 00:11
doctest_aliases.py
240
B
-rw-r--r--
2024-09-07 00:11
double_const.py
1.18
KB
-rw-r--r--
2024-09-07 00:11
empty.vbs
70
B
-rw-r--r--
2024-09-07 00:11
exception_hierarchy.txt
1.78
KB
-rw-r--r--
2024-09-07 00:11
ffdh3072.pem
2.16
KB
-rw-r--r--
2024-09-07 00:11
final_a.py
411
B
-rw-r--r--
2024-09-07 00:11
final_b.py
411
B
-rw-r--r--
2024-09-07 00:11
floating_points.txt
15.92
KB
-rw-r--r--
2024-09-07 00:11
fork_wait.py
2.53
KB
-rw-r--r--
2024-09-07 00:11
formatfloat_testcases.txt
7.45
KB
-rw-r--r--
2024-09-07 00:11
future_test1.py
229
B
-rw-r--r--
2024-09-07 00:11
future_test2.py
149
B
-rw-r--r--
2024-09-07 00:11
gdb_sample.py
153
B
-rw-r--r--
2024-09-07 00:11
good_getattr.py
198
B
-rw-r--r--
2024-09-07 00:11
idnsans.pem
9.71
KB
-rw-r--r--
2024-09-07 00:11
ieee754.txt
3.21
KB
-rw-r--r--
2024-09-07 00:11
imp_dummy.py
63
B
-rw-r--r--
2024-09-07 00:11
inspect_fodder.py
1.88
KB
-rw-r--r--
2024-09-07 00:11
inspect_fodder2.py
2.06
KB
-rw-r--r--
2024-09-07 00:11
keycert.passwd.pem
4.13
KB
-rw-r--r--
2024-09-07 00:11
keycert.pem
3.96
KB
-rw-r--r--
2024-09-07 00:11
keycert2.pem
3.98
KB
-rw-r--r--
2024-09-07 00:11
keycert3.pem
9.23
KB
-rw-r--r--
2024-09-07 00:11
keycert4.pem
9.24
KB
-rw-r--r--
2024-09-07 00:11
keycertecc.pem
5.5
KB
-rw-r--r--
2024-09-07 00:11
list_tests.py
16.54
KB
-rw-r--r--
2024-09-07 00:11
lock_tests.py
28.26
KB
-rw-r--r--
2024-09-07 00:11
mailcap.txt
1.24
KB
-rw-r--r--
2024-09-07 00:11
make_ssl_certs.py
9.25
KB
-rw-r--r--
2024-09-07 00:11
mapping_tests.py
21.75
KB
-rw-r--r--
2024-09-07 00:11
math_testcases.txt
23.19
KB
-rw-r--r--
2024-09-07 00:11
memory_watchdog.py
859
B
-rw-r--r--
2024-09-07 00:11
mime.types
47.37
KB
-rw-r--r--
2024-09-07 00:11
mock_socket.py
3.53
KB
-rw-r--r--
2024-09-07 00:11
mod_generics_cache.py
1.13
KB
-rw-r--r--
2024-09-07 00:11
mp_fork_bomb.py
448
B
-rw-r--r--
2024-09-07 00:11
mp_preload.py
351
B
-rw-r--r--
2024-09-07 00:11
multibytecodec_support.py
14.17
KB
-rw-r--r--
2024-09-07 00:11
nokia.pem
1.88
KB
-rw-r--r--
2024-09-07 00:11
nosan.pem
7.54
KB
-rw-r--r--
2024-09-07 00:11
nullbytecert.pem
5.31
KB
-rw-r--r--
2024-09-07 00:11
nullcert.pem
0
B
-rw-r--r--
2024-09-07 00:11
outstanding_bugs.py
370
B
-rw-r--r--
2024-09-07 00:11
pickletester.py
135.99
KB
-rw-r--r--
2024-09-07 00:11
profilee.py
2.97
KB
-rw-r--r--
2024-09-07 00:11
pstats.pck
65.05
KB
-rw-r--r--
2024-09-07 00:11
pycacert.pem
5.53
KB
-rw-r--r--
2024-09-07 00:11
pycakey.pem
2.43
KB
-rw-r--r--
2024-09-07 00:11
pyclbr_input.py
648
B
-rw-r--r--
2024-09-07 00:11
pydoc_mod.py
713
B
-rw-r--r--
2024-09-07 00:11
pydocfodder.py
6.18
KB
-rw-r--r--
2024-09-07 00:11
pythoninfo.py
20.34
KB
-rw-r--r--
2024-09-07 00:11
randv2_32.pck
7.34
KB
-rw-r--r--
2024-09-07 00:11
randv2_64.pck
7.19
KB
-rw-r--r--
2024-09-07 00:11
randv3.pck
7.82
KB
-rw-r--r--
2024-09-07 00:11
re_tests.py
25.94
KB
-rwxr-xr-x
2024-09-07 00:11
recursion.tar
516
B
-rw-r--r--
2024-09-07 00:11
regrtest.py
1.34
KB
-rwxr-xr-x
2024-09-07 00:11
relimport.py
27
B
-rw-r--r--
2024-09-07 00:11
reperf.py
538
B
-rw-r--r--
2024-09-07 00:11
revocation.crl
800
B
-rw-r--r--
2024-09-07 00:11
sample_doctest.py
1.02
KB
-rw-r--r--
2024-09-07 00:11
sample_doctest_no_docstrings.py
227
B
-rw-r--r--
2024-09-07 00:11
sample_doctest_no_doctests.py
269
B
-rw-r--r--
2024-09-07 00:11
secp384r1.pem
256
B
-rw-r--r--
2024-09-07 00:11
selfsigned_pythontestdotnet.pem
2.08
KB
-rw-r--r--
2024-09-07 00:11
seq_tests.py
14.18
KB
-rw-r--r--
2024-09-07 00:11
sgml_input.html
8.1
KB
-rw-r--r--
2024-09-07 00:11
signalinterproctester.py
2.7
KB
-rw-r--r--
2024-09-07 00:11
sortperf.py
4.69
KB
-rw-r--r--
2024-09-07 00:11
ssl_cert.pem
1.53
KB
-rw-r--r--
2024-09-07 00:11
ssl_key.passwd.pem
2.59
KB
-rw-r--r--
2024-09-07 00:11
ssl_key.pem
2.43
KB
-rw-r--r--
2024-09-07 00:11
ssl_servers.py
7.04
KB
-rw-r--r--
2024-09-07 00:11
ssltests.py
1.03
KB
-rw-r--r--
2024-09-07 00:11
string_tests.py
64.65
KB
-rw-r--r--
2024-09-07 00:11
talos-2019-0758.pem
1.3
KB
-rw-r--r--
2024-09-07 00:11
test___all__.py
4.12
KB
-rw-r--r--
2024-09-07 00:11
test___future__.py
2.36
KB
-rw-r--r--
2024-09-07 00:11
test__locale.py
7.83
KB
-rw-r--r--
2024-09-07 00:11
test__opcode.py
3.03
KB
-rw-r--r--
2024-09-07 00:11
test__osx_support.py
13.66
KB
-rw-r--r--
2024-09-07 00:11
test__xxsubinterpreters.py
68.7
KB
-rw-r--r--
2024-09-07 00:11
test_abc.py
18
KB
-rw-r--r--
2024-09-07 00:11
test_abstract_numbers.py
1.49
KB
-rw-r--r--
2024-09-07 00:11
test_aifc.py
17.68
KB
-rw-r--r--
2024-09-07 00:11
test_argparse.py
172.67
KB
-rw-r--r--
2024-09-07 00:11
test_array.py
52.57
KB
-rw-r--r--
2024-09-07 00:11
test_asdl_parser.py
4.15
KB
-rw-r--r--
2024-09-07 00:11
test_ast.py
88.92
KB
-rw-r--r--
2024-09-07 00:11
test_asyncgen.py
31.44
KB
-rw-r--r--
2024-09-07 00:11
test_asynchat.py
9.28
KB
-rw-r--r--
2024-09-07 00:11
test_asyncore.py
25.81
KB
-rw-r--r--
2024-09-07 00:11
test_atexit.py
5.81
KB
-rw-r--r--
2024-09-07 00:11
test_audioop.py
28.24
KB
-rw-r--r--
2024-09-07 00:11
test_audit.py
4.19
KB
-rw-r--r--
2024-09-07 00:11
test_augassign.py
7.68
KB
-rw-r--r--
2024-09-07 00:11
test_base64.py
30.17
KB
-rw-r--r--
2024-09-07 00:11
test_baseexception.py
6.86
KB
-rw-r--r--
2024-09-07 00:11
test_bdb.py
41.55
KB
-rw-r--r--
2024-09-07 00:11
test_bigaddrspace.py
2.92
KB
-rw-r--r--
2024-09-07 00:11
test_bigmem.py
44.88
KB
-rw-r--r--
2024-09-07 00:11
test_binascii.py
18
KB
-rw-r--r--
2024-09-07 00:11
test_binhex.py
1.79
KB
-rw-r--r--
2024-09-07 00:11
test_binop.py
14.14
KB
-rw-r--r--
2024-09-07 00:11
test_bisect.py
13.63
KB
-rw-r--r--
2024-09-07 00:11
test_bool.py
12.48
KB
-rw-r--r--
2024-09-07 00:11
test_buffer.py
160.04
KB
-rw-r--r--
2024-09-07 00:11
test_bufio.py
2.54
KB
-rw-r--r--
2024-09-07 00:11
test_builtin.py
78.38
KB
-rw-r--r--
2024-09-07 00:11
test_bytes.py
72.23
KB
-rw-r--r--
2024-09-07 00:11
test_bz2.py
36.76
KB
-rw-r--r--
2024-09-07 00:11
test_c_locale_coercion.py
18.82
KB
-rw-r--r--
2024-09-07 00:11
test_calendar.py
48.71
KB
-rw-r--r--
2024-09-07 00:11
test_call.py
20.88
KB
-rw-r--r--
2024-09-07 00:11
test_capi.py
30.46
KB
-rw-r--r--
2024-09-07 00:11
test_cgi.py
22.15
KB
-rw-r--r--
2024-09-07 00:11
test_cgitb.py
2.5
KB
-rw-r--r--
2024-09-07 00:11
test_charmapcodec.py
1.68
KB
-rw-r--r--
2024-09-07 00:11
test_class.py
17.42
KB
-rw-r--r--
2024-09-07 00:11
test_clinic.py
21.71
KB
-rw-r--r--
2024-09-07 00:11
test_cmath.py
24.07
KB
-rw-r--r--
2024-09-07 00:11
test_cmd.py
6.1
KB
-rw-r--r--
2024-09-07 00:11
test_cmd_line.py
35.38
KB
-rw-r--r--
2024-09-07 00:11
test_cmd_line_script.py
31.46
KB
-rw-r--r--
2024-09-07 00:11
test_code.py
13.66
KB
-rw-r--r--
2024-09-07 00:11
test_code_module.py
5.51
KB
-rw-r--r--
2024-09-07 00:11
test_codeccallbacks.py
40.97
KB
-rw-r--r--
2024-09-07 00:11
test_codecencodings_cn.py
3.86
KB
-rw-r--r--
2024-09-07 00:11
test_codecencodings_hk.py
701
B
-rw-r--r--
2024-09-07 00:11
test_codecencodings_iso2022.py
3.65
KB
-rw-r--r--
2024-09-07 00:11
test_codecencodings_jp.py
4.79
KB
-rw-r--r--
2024-09-07 00:11
test_codecencodings_kr.py
2.96
KB
-rw-r--r--
2024-09-07 00:11
test_codecencodings_tw.py
681
B
-rw-r--r--
2024-09-07 00:11
test_codecmaps_cn.py
746
B
-rw-r--r--
2024-09-07 00:11
test_codecmaps_hk.py
386
B
-rw-r--r--
2024-09-07 00:11
test_codecmaps_jp.py
1.7
KB
-rw-r--r--
2024-09-07 00:11
test_codecmaps_kr.py
1.16
KB
-rw-r--r--
2024-09-07 00:11
test_codecmaps_tw.py
705
B
-rw-r--r--
2024-09-07 00:11
test_codecs.py
129.64
KB
-rw-r--r--
2024-09-07 00:11
test_codeop.py
7.97
KB
-rw-r--r--
2024-09-07 00:11
test_collections.py
83.96
KB
-rw-r--r--
2024-09-07 00:11
test_colorsys.py
3.83
KB
-rw-r--r--
2024-09-07 00:11
test_compare.py
3.82
KB
-rw-r--r--
2024-09-07 00:11
test_compile.py
37.07
KB
-rw-r--r--
2024-09-07 00:11
test_compileall.py
26.7
KB
-rw-r--r--
2024-09-07 00:11
test_complex.py
30.24
KB
-rw-r--r--
2024-09-07 00:11
test_concurrent_futures.py
44.93
KB
-rw-r--r--
2024-09-07 00:11
test_configparser.py
84.93
KB
-rw-r--r--
2024-09-07 00:11
test_contains.py
3.49
KB
-rw-r--r--
2024-09-07 00:11
test_context.py
30.74
KB
-rw-r--r--
2024-09-07 00:11
test_contextlib.py
32.54
KB
-rw-r--r--
2024-09-07 00:11
test_contextlib_async.py
14.82
KB
-rw-r--r--
2024-09-07 00:11
test_copy.py
25.81
KB
-rw-r--r--
2024-09-07 00:11
test_copyreg.py
4.39
KB
-rw-r--r--
2024-09-07 00:11
test_coroutines.py
62.52
KB
-rw-r--r--
2024-09-07 00:11
test_cprofile.py
6.33
KB
-rw-r--r--
2024-09-07 00:11
test_crashers.py
1.17
KB
-rw-r--r--
2024-09-07 00:11
test_crypt.py
3.97
KB
-rw-r--r--
2024-09-07 00:11
test_csv.py
47.77
KB
-rw-r--r--
2024-09-07 00:11
test_ctypes.py
184
B
-rw-r--r--
2024-09-07 00:11
test_curses.py
45.47
KB
-rw-r--r--
2024-09-07 00:11
test_dataclasses.py
108.8
KB
-rw-r--r--
2024-09-07 00:11
test_datetime.py
2.15
KB
-rw-r--r--
2024-09-07 00:11
test_dbm.py
6.45
KB
-rw-r--r--
2024-09-07 00:11
test_dbm_dumb.py
10.61
KB
-rw-r--r--
2024-09-07 00:11
test_dbm_gnu.py
6.22
KB
-rw-r--r--
2024-09-07 00:11
test_dbm_ndbm.py
5.05
KB
-rw-r--r--
2024-09-07 00:11
test_decimal.py
207.14
KB
-rw-r--r--
2024-09-07 00:11
test_decorators.py
9.48
KB
-rw-r--r--
2024-09-07 00:11
test_defaultdict.py
5.88
KB
-rw-r--r--
2024-09-07 00:11
test_deque.py
34.46
KB
-rw-r--r--
2024-09-07 00:11
test_descr.py
190.58
KB
-rw-r--r--
2024-09-07 00:11
test_descrtut.py
11.53
KB
-rw-r--r--
2024-09-07 00:11
test_devpoll.py
4.5
KB
-rw-r--r--
2024-09-07 00:11
test_dict.py
45
KB
-rw-r--r--
2024-09-07 00:11
test_dict_version.py
5.88
KB
-rw-r--r--
2024-09-07 00:11
test_dictcomps.py
4.42
KB
-rw-r--r--
2024-09-07 00:11
test_dictviews.py
11.68
KB
-rw-r--r--
2024-09-07 00:11
test_difflib.py
19.64
KB
-rw-r--r--
2024-09-07 00:11
test_difflib_expect.html
100.85
KB
-rw-r--r--
2024-09-07 00:11
test_dis.py
48.4
KB
-rw-r--r--
2024-09-07 00:11
test_distutils.py
375
B
-rw-r--r--
2024-09-07 00:11
test_doctest.py
98.67
KB
-rw-r--r--
2024-09-07 00:11
test_doctest.txt
300
B
-rw-r--r--
2024-09-07 00:11
test_doctest2.py
2.3
KB
-rw-r--r--
2024-09-07 00:11
test_doctest2.txt
392
B
-rw-r--r--
2024-09-07 00:11
test_doctest3.txt
82
B
-rw-r--r--
2024-09-07 00:11
test_doctest4.txt
244
B
-rw-r--r--
2024-09-07 00:11
test_docxmlrpc.py
8.67
KB
-rw-r--r--
2024-09-07 00:11
test_dtrace.py
5.23
KB
-rw-r--r--
2024-09-07 00:11
test_dummy_thread.py
9.69
KB
-rw-r--r--
2024-09-07 00:11
test_dummy_threading.py
1.7
KB
-rw-r--r--
2024-09-07 00:11
test_dynamic.py
4.29
KB
-rw-r--r--
2024-09-07 00:11
test_dynamicclassattribute.py
9.57
KB
-rw-r--r--
2024-09-07 00:11
test_eintr.py
1.32
KB
-rw-r--r--
2024-09-07 00:11
test_embed.py
49.23
KB
-rw-r--r--
2024-09-07 00:11
test_ensurepip.py
9.83
KB
-rw-r--r--
2024-09-07 00:11
test_enum.py
113.68
KB
-rw-r--r--
2024-09-07 00:11
test_enumerate.py
8.46
KB
-rw-r--r--
2024-09-07 00:11
test_eof.py
1.94
KB
-rw-r--r--
2024-09-07 00:11
test_epoll.py
9.03
KB
-rw-r--r--
2024-09-07 00:11
test_errno.py
1.04
KB
-rw-r--r--
2024-09-07 00:11
test_exception_hierarchy.py
7.43
KB
-rw-r--r--
2024-09-07 00:11
test_exception_variations.py
3.86
KB
-rw-r--r--
2024-09-07 00:11
test_exceptions.py
49.81
KB
-rw-r--r--
2024-09-07 00:11
test_extcall.py
13.49
KB
-rw-r--r--
2024-09-07 00:11
test_faulthandler.py
28.13
KB
-rw-r--r--
2024-09-07 00:11
test_fcntl.py
6.21
KB
-rw-r--r--
2024-09-07 00:11
test_file.py
11.02
KB
-rw-r--r--
2024-09-07 00:11
test_file_eintr.py
10.6
KB
-rw-r--r--
2024-09-07 00:11
test_filecmp.py
8.69
KB
-rw-r--r--
2024-09-07 00:11
test_fileinput.py
37.33
KB
-rw-r--r--
2024-09-07 00:11
test_fileio.py
19.96
KB
-rw-r--r--
2024-09-07 00:11
test_finalization.py
14.66
KB
-rw-r--r--
2024-09-07 00:11
test_float.py
63.41
KB
-rw-r--r--
2024-09-07 00:11
test_flufl.py
1.32
KB
-rw-r--r--
2024-09-07 00:11
test_fnmatch.py
5.07
KB
-rw-r--r--
2024-09-07 00:11
test_fork1.py
3.67
KB
-rw-r--r--
2024-09-07 00:11
test_format.py
22.58
KB
-rw-r--r--
2024-09-07 00:11
test_fractions.py
29.83
KB
-rw-r--r--
2024-09-07 00:11
test_frame.py
5.67
KB
-rw-r--r--
2024-09-07 00:11
test_frozen.py
943
B
-rw-r--r--
2024-09-07 00:11
test_fstring.py
46.16
KB
-rw-r--r--
2024-09-07 00:11
test_ftplib.py
39.71
KB
-rw-r--r--
2024-09-07 00:11
test_funcattrs.py
13.54
KB
-rw-r--r--
2024-09-07 00:11
test_functools.py
90.59
KB
-rw-r--r--
2024-09-07 00:11
test_future.py
11.9
KB
-rw-r--r--
2024-09-07 00:11
test_future3.py
490
B
-rw-r--r--
2024-09-07 00:11
test_future4.py
222
B
-rw-r--r--
2024-09-07 00:11
test_future5.py
510
B
-rw-r--r--
2024-09-07 00:11
test_gc.py
40.49
KB
-rw-r--r--
2024-09-07 00:11
test_gdb.py
40.88
KB
-rw-r--r--
2024-09-07 00:11
test_generator_stop.py
943
B
-rw-r--r--
2024-09-07 00:11
test_generators.py
58.51
KB
-rw-r--r--
2024-09-07 00:11
test_genericclass.py
9.28
KB
-rw-r--r--
2024-09-07 00:11
test_genericpath.py
21.7
KB
-rw-r--r--
2024-09-07 00:11
test_genexps.py
7.12
KB
-rw-r--r--
2024-09-07 00:11
test_getargs2.py
50
KB
-rw-r--r--
2024-09-07 00:11
test_getopt.py
6.75
KB
-rw-r--r--
2024-09-07 00:11
test_getpass.py
6.29
KB
-rw-r--r--
2024-09-07 00:11
test_gettext.py
41.38
KB
-rw-r--r--
2024-09-07 00:11
test_glob.py
13.03
KB
-rw-r--r--
2024-09-07 00:11
test_global.py
1.31
KB
-rw-r--r--
2024-09-07 00:11
test_grammar.py
57.5
KB
-rw-r--r--
2024-09-07 00:11
test_grp.py
3.54
KB
-rw-r--r--
2024-09-07 00:11
test_gzip.py
29.9
KB
-rw-r--r--
2024-09-07 00:11
test_hash.py
11.45
KB
-rw-r--r--
2024-09-07 00:11
test_hashlib.py
39.86
KB
-rw-r--r--
2024-09-07 00:11
test_heapq.py
16.4
KB
-rw-r--r--
2024-09-07 00:11
test_hmac.py
22.24
KB
-rw-r--r--
2024-09-07 00:11
test_html.py
4.23
KB
-rw-r--r--
2024-09-07 00:11
test_htmlparser.py
33.19
KB
-rw-r--r--
2024-09-07 00:11
test_http_cookiejar.py
78.36
KB
-rw-r--r--
2024-09-07 00:11
test_http_cookies.py
20.02
KB
-rw-r--r--
2024-09-07 00:11
test_httplib.py
76.98
KB
-rw-r--r--
2024-09-07 00:11
test_httpservers.py
49.48
KB
-rw-r--r--
2024-09-07 00:11
test_idle.py
825
B
-rw-r--r--
2024-09-07 00:11
test_imaplib.py
38.95
KB
-rw-r--r--
2024-09-07 00:11
test_imghdr.py
4.66
KB
-rw-r--r--
2024-09-07 00:11
test_imp.py
17.73
KB
-rw-r--r--
2024-09-07 00:11
test_index.py
8.37
KB
-rw-r--r--
2024-09-07 00:11
test_inspect.py
151.79
KB
-rw-r--r--
2024-09-07 00:11
test_int.py
28.41
KB
-rw-r--r--
2024-09-07 00:11
test_int_literal.py
6.89
KB
-rw-r--r--
2024-09-07 00:11
test_io.py
163.94
KB
-rw-r--r--
2024-09-07 00:11
test_ioctl.py
3.2
KB
-rw-r--r--
2024-09-07 00:11
test_ipaddress.py
94.41
KB
-rw-r--r--
2024-09-07 00:11
test_isinstance.py
10.25
KB
-rw-r--r--
2024-09-07 00:11
test_iter.py
31.81
KB
-rw-r--r--
2024-09-07 00:11
test_iterlen.py
7.1
KB
-rw-r--r--
2024-09-07 00:11
test_itertools.py
101.41
KB
-rw-r--r--
2024-09-07 00:11
test_keyword.py
1.23
KB
-rw-r--r--
2024-09-07 00:11
test_keywordonlyarg.py
6.85
KB
-rw-r--r--
2024-09-07 00:11
test_kqueue.py
8.76
KB
-rw-r--r--
2024-09-07 00:11
test_largefile.py
6.83
KB
-rw-r--r--
2024-09-07 00:11
test_lib2to3.py
101
B
-rw-r--r--
2024-09-07 00:11
test_linecache.py
7.79
KB
-rw-r--r--
2024-09-07 00:11
test_list.py
7.84
KB
-rw-r--r--
2024-09-07 00:11
test_listcomps.py
3.76
KB
-rw-r--r--
2024-09-07 00:11
test_lltrace.py
1012
B
-rw-r--r--
2024-09-07 00:11
test_locale.py
23.87
KB
-rw-r--r--
2024-09-07 00:11
test_logging.py
182.43
KB
-rw-r--r--
2024-09-07 00:11
test_long.py
53.21
KB
-rw-r--r--
2024-09-07 00:11
test_longexp.py
233
B
-rw-r--r--
2024-09-07 00:11
test_lzma.py
87.92
KB
-rw-r--r--
2024-09-07 00:11
test_mailbox.py
91.92
KB
-rw-r--r--
2024-09-07 00:11
test_mailcap.py
10.03
KB
-rw-r--r--
2024-09-07 00:11
test_marshal.py
20.57
KB
-rw-r--r--
2024-09-07 00:11
test_math.py
82.18
KB
-rw-r--r--
2024-09-07 00:11
test_memoryio.py
31.48
KB
-rw-r--r--
2024-09-07 00:11
test_memoryview.py
17.78
KB
-rw-r--r--
2024-09-07 00:11
test_metaclass.py
6.2
KB
-rw-r--r--
2024-09-07 00:11
test_mimetypes.py
12.14
KB
-rw-r--r--
2024-09-07 00:11
test_minidom.py
67.34
KB
-rw-r--r--
2024-09-23 14:45
test_mmap.py
29.23
KB
-rw-r--r--
2024-09-07 00:11
test_module.py
10.3
KB
-rw-r--r--
2024-09-07 00:11
test_modulefinder.py
12.2
KB
-rw-r--r--
2024-09-07 00:11
test_msilib.py
5.06
KB
-rw-r--r--
2024-09-07 00:11
test_multibytecodec.py
15.04
KB
-rw-r--r--
2024-09-07 00:11
test_multiprocessing_fork.py
477
B
-rw-r--r--
2024-09-07 00:11
test_multiprocessing_forkserver.py
392
B
-rw-r--r--
2024-09-07 00:11
test_multiprocessing_main_handling.py
11.45
KB
-rw-r--r--
2024-09-07 00:11
test_multiprocessing_spawn.py
277
B
-rw-r--r--
2024-09-07 00:11
test_named_expressions.py
16.51
KB
-rw-r--r--
2024-09-07 00:11
test_netrc.py
5.96
KB
-rw-r--r--
2024-09-07 00:11
test_nis.py
1.13
KB
-rw-r--r--
2024-09-07 00:11
test_nntplib.py
61.7
KB
-rw-r--r--
2024-09-07 00:11
test_normalization.py
3.66
KB
-rw-r--r--
2024-09-07 00:11
test_ntpath.py
35.08
KB
-rw-r--r--
2024-09-07 00:11
test_numeric_tower.py
7.18
KB
-rw-r--r--
2024-09-07 00:11
test_opcodes.py
3.61
KB
-rw-r--r--
2024-09-07 00:11
test_openpty.py
600
B
-rw-r--r--
2024-09-07 00:11
test_operator.py
23.54
KB
-rw-r--r--
2024-09-07 00:11
test_optparse.py
60.99
KB
-rw-r--r--
2024-09-07 00:11
test_ordered_dict.py
30.22
KB
-rw-r--r--
2024-09-07 00:11
test_os.py
150.99
KB
-rw-r--r--
2024-09-07 00:11
test_ossaudiodev.py
7.06
KB
-rw-r--r--
2024-09-07 00:11
test_osx_env.py
1.3
KB
-rw-r--r--
2024-09-07 00:11
test_parser.py
35.72
KB
-rw-r--r--
2024-09-07 00:11
test_pathlib.py
97.12
KB
-rw-r--r--
2024-09-07 00:11
test_pdb.py
55.36
KB
-rw-r--r--
2024-09-07 00:11
test_peepholer.py
19.41
KB
-rw-r--r--
2024-09-07 00:11
test_pickle.py
19.16
KB
-rw-r--r--
2024-09-07 00:11
test_picklebuffer.py
4.96
KB
-rw-r--r--
2024-09-07 00:11
test_pickletools.py
4.33
KB
-rw-r--r--
2024-09-07 00:11
test_pipes.py
6.59
KB
-rw-r--r--
2024-09-07 00:11
test_pkg.py
9.59
KB
-rw-r--r--
2024-09-07 00:11
test_pkgimport.py
2.67
KB
-rw-r--r--
2024-09-07 00:11
test_pkgutil.py
19.25
KB
-rw-r--r--
2024-09-07 00:11
test_platform.py
14.31
KB
-rw-r--r--
2024-09-07 00:11
test_plistlib.py
41.43
KB
-rw-r--r--
2024-09-07 00:11
test_poll.py
7.23
KB
-rw-r--r--
2024-09-07 00:11
test_popen.py
1.98
KB
-rw-r--r--
2024-09-07 00:11
test_poplib.py
16.97
KB
-rw-r--r--
2024-09-07 00:11
test_positional_only_arg.py
17.5
KB
-rw-r--r--
2024-09-07 00:11
test_posix.py
75.76
KB
-rw-r--r--
2024-09-07 00:11
test_posixpath.py
29.19
KB
-rw-r--r--
2024-09-07 00:11
test_pow.py
5.44
KB
-rw-r--r--
2024-09-07 00:11
test_pprint.py
43.85
KB
-rw-r--r--
2024-09-07 00:11
test_print.py
7.37
KB
-rw-r--r--
2024-09-07 00:11
test_profile.py
8.72
KB
-rw-r--r--
2024-09-07 00:11
test_property.py
8.77
KB
-rw-r--r--
2024-09-07 00:11
test_pstats.py
3.04
KB
-rw-r--r--
2024-09-07 00:11
test_pty.py
11.97
KB
-rw-r--r--
2024-09-07 00:11
test_pulldom.py
12.66
KB
-rw-r--r--
2024-09-07 00:11
test_pwd.py
4.17
KB
-rw-r--r--
2024-09-07 00:11
test_py_compile.py
10.85
KB
-rw-r--r--
2024-09-23 14:45
test_pyclbr.py
10
KB
-rw-r--r--
2024-09-07 00:11
test_pydoc.py
56.98
KB
-rw-r--r--
2024-09-07 00:11
test_pyexpat.py
27.71
KB
-rw-r--r--
2024-09-23 14:45
test_queue.py
20.36
KB
-rw-r--r--
2024-09-07 00:11
test_quopri.py
7.78
KB
-rw-r--r--
2024-09-07 00:11
test_raise.py
12.86
KB
-rw-r--r--
2024-09-07 00:11
test_random.py
45.59
KB
-rw-r--r--
2024-09-07 00:11
test_range.py
23.35
KB
-rw-r--r--
2024-09-07 00:11
test_re.py
106.41
KB
-rw-r--r--
2024-09-07 00:11
test_readline.py
13.29
KB
-rw-r--r--
2024-09-07 00:11
test_regrtest.py
46.36
KB
-rw-r--r--
2024-09-07 00:11
test_repl.py
3.96
KB
-rw-r--r--
2024-09-07 00:11
test_reprlib.py
15.12
KB
-rw-r--r--
2024-09-07 00:11
test_resource.py
7.02
KB
-rw-r--r--
2024-09-07 00:11
test_richcmp.py
11.91
KB
-rw-r--r--
2024-09-07 00:11
test_rlcompleter.py
6.3
KB
-rw-r--r--
2024-09-07 00:11
test_robotparser.py
10.69
KB
-rw-r--r--
2024-09-07 00:11
test_runpy.py
33.86
KB
-rw-r--r--
2024-09-07 00:11
test_sax.py
47.75
KB
-rw-r--r--
2024-09-23 14:45
test_sched.py
6.41
KB
-rw-r--r--
2024-09-07 00:11
test_scope.py
19.7
KB
-rw-r--r--
2024-09-07 00:11
test_script_helper.py
5.78
KB
-rw-r--r--
2024-09-07 00:11
test_secrets.py
4.28
KB
-rw-r--r--
2024-09-07 00:11
test_select.py
2.69
KB
-rw-r--r--
2024-09-07 00:11
test_selectors.py
17.79
KB
-rw-r--r--
2024-09-07 00:11
test_set.py
64.41
KB
-rw-r--r--
2024-09-07 00:11
test_setcomps.py
3.7
KB
-rw-r--r--
2024-09-07 00:11
test_shelve.py
6.24
KB
-rw-r--r--
2024-09-07 00:11
test_shlex.py
13.29
KB
-rw-r--r--
2024-09-07 00:11
test_shutil.py
102.11
KB
-rw-r--r--
2024-09-07 00:11
test_signal.py
46.62
KB
-rw-r--r--
2024-09-07 00:11
test_site.py
26.22
KB
-rw-r--r--
2024-09-23 14:45
test_slice.py
8.25
KB
-rw-r--r--
2024-09-07 00:11
test_smtpd.py
40.14
KB
-rw-r--r--
2024-09-07 00:11
test_smtplib.py
56.51
KB
-rw-r--r--
2024-09-07 00:11
test_smtpnet.py
2.87
KB
-rw-r--r--
2024-09-07 00:11
test_sndhdr.py
1.43
KB
-rw-r--r--
2024-09-07 00:11
test_socket.py
237.22
KB
-rw-r--r--
2024-09-07 00:11
test_socketserver.py
17.7
KB
-rw-r--r--
2024-09-07 00:11
test_sort.py
13.42
KB
-rw-r--r--
2024-09-07 00:11
test_source_encoding.py
7.89
KB
-rw-r--r--
2024-09-07 00:11
test_spwd.py
2.71
KB
-rw-r--r--
2024-09-07 00:11
test_sqlite.py
948
B
-rw-r--r--
2024-09-07 00:11
test_ssl.py
214.82
KB
-rw-r--r--
2024-09-07 00:11
test_startfile.py
1.29
KB
-rw-r--r--
2024-09-07 00:11
test_stat.py
8.3
KB
-rw-r--r--
2024-09-07 00:11
test_statistics.py
106.5
KB
-rw-r--r--
2024-09-07 00:11
test_strftime.py
7.54
KB
-rw-r--r--
2024-09-07 00:11
test_string.py
19.8
KB
-rw-r--r--
2024-09-07 00:11
test_string_literals.py
9.88
KB
-rw-r--r--
2024-09-07 00:11
test_stringprep.py
3.04
KB
-rw-r--r--
2024-09-07 00:11
test_strptime.py
34.42
KB
-rw-r--r--
2024-09-07 00:11
test_strtod.py
20.06
KB
-rw-r--r--
2024-09-07 00:11
test_struct.py
34.41
KB
-rw-r--r--
2024-09-07 00:11
test_structmembers.py
4.7
KB
-rw-r--r--
2024-09-07 00:11
test_structseq.py
3.87
KB
-rw-r--r--
2024-09-07 00:11
test_subclassinit.py
8.12
KB
-rw-r--r--
2024-09-07 00:11
test_subprocess.py
142.64
KB
-rw-r--r--
2024-09-07 00:11
test_sunau.py
6.07
KB
-rw-r--r--
2024-09-07 00:11
test_sundry.py
2.07
KB
-rw-r--r--
2024-09-07 00:11
test_super.py
9.6
KB
-rw-r--r--
2024-09-07 00:11
test_support.py
24.12
KB
-rw-r--r--
2024-09-07 00:11
test_symbol.py
2.06
KB
-rw-r--r--
2024-09-07 00:11
test_symtable.py
9.13
KB
-rw-r--r--
2024-09-07 00:11
test_syntax.py
25.75
KB
-rw-r--r--
2024-09-07 00:11
test_sys.py
55.68
KB
-rw-r--r--
2024-09-07 00:11
test_sys_setprofile.py
12.31
KB
-rw-r--r--
2024-09-07 00:11
test_sys_settrace.py
43.08
KB
-rw-r--r--
2024-09-07 00:11
test_sysconfig.py
17.01
KB
-rw-r--r--
2024-09-07 00:11
test_syslog.py
1.15
KB
-rw-r--r--
2024-09-07 00:11
test_tabnanny.py
13.44
KB
-rw-r--r--
2024-09-07 00:11
test_tarfile.py
144.04
KB
-rw-r--r--
2024-09-07 00:11
test_tcl.py
30.74
KB
-rw-r--r--
2024-09-07 00:11
test_telnetlib.py
12.7
KB
-rw-r--r--
2024-09-07 00:11
test_tempfile.py
58.51
KB
-rw-r--r--
2024-09-07 00:11
test_textwrap.py
38.84
KB
-rw-r--r--
2024-09-07 00:11
test_thread.py
8.41
KB
-rw-r--r--
2024-09-07 00:11
test_threaded_import.py
8.9
KB
-rw-r--r--
2024-09-07 00:11
test_threadedtempfile.py
1.85
KB
-rw-r--r--
2024-09-07 00:11
test_threading.py
47.52
KB
-rw-r--r--
2024-09-07 00:11
test_threading_local.py
6.09
KB
-rw-r--r--
2024-09-07 00:11
test_threadsignals.py
10.09
KB
-rw-r--r--
2024-09-07 00:11
test_time.py
38.43
KB
-rw-r--r--
2024-09-07 00:11
test_timeit.py
14.8
KB
-rw-r--r--
2024-09-07 00:11
test_timeout.py
11.19
KB
-rw-r--r--
2024-09-07 00:11
test_tix.py
756
B
-rw-r--r--
2024-09-07 00:11
test_tk.py
362
B
-rw-r--r--
2024-09-07 00:11
test_tokenize.py
63.18
KB
-rw-r--r--
2024-09-07 00:11
test_trace.py
19.89
KB
-rw-r--r--
2024-09-07 00:11
test_traceback.py
46.97
KB
-rw-r--r--
2024-09-07 00:11
test_tracemalloc.py
37.41
KB
-rw-r--r--
2024-09-07 00:11
test_ttk_guionly.py
746
B
-rw-r--r--
2024-09-07 00:11
test_ttk_textonly.py
299
B
-rw-r--r--
2024-09-07 00:11
test_tuple.py
18.85
KB
-rw-r--r--
2024-09-07 00:11
test_turtle.py
12.79
KB
-rw-r--r--
2024-09-07 00:11
test_type_comments.py
10.13
KB
-rw-r--r--
2024-09-07 00:11
test_typechecks.py
2.55
KB
-rw-r--r--
2024-09-07 00:11
test_types.py
58
KB
-rw-r--r--
2024-09-07 00:11
test_typing.py
122.05
KB
-rw-r--r--
2024-09-07 00:11
test_ucn.py
9.35
KB
-rw-r--r--
2024-09-07 00:11
test_unary.py
1.63
KB
-rw-r--r--
2024-09-07 00:11
test_unicode.py
129.94
KB
-rw-r--r--
2024-09-07 00:11
test_unicode_file.py
5.74
KB
-rw-r--r--
2024-09-07 00:11
test_unicode_file_functions.py
6.84
KB
-rw-r--r--
2024-09-07 00:11
test_unicode_identifiers.py
891
B
-rw-r--r--
2024-09-07 00:11
test_unicodedata.py
12.7
KB
-rw-r--r--
2024-09-07 00:11
test_unittest.py
286
B
-rw-r--r--
2024-09-07 00:11
test_univnewlines.py
3.83
KB
-rw-r--r--
2024-09-07 00:11
test_unpack.py
3.01
KB
-rw-r--r--
2024-09-07 00:11
test_unpack_ex.py
8.73
KB
-rw-r--r--
2024-09-07 00:11
test_urllib.py
71.24
KB
-rw-r--r--
2024-09-07 00:11
test_urllib2.py
79.44
KB
-rw-r--r--
2024-09-07 00:11
test_urllib2_localnet.py
24.24
KB
-rw-r--r--
2024-09-07 00:11
test_urllib2net.py
12.39
KB
-rw-r--r--
2024-09-07 00:11
test_urllib_response.py
1.69
KB
-rw-r--r--
2024-09-07 00:11
test_urllibnet.py
8.9
KB
-rw-r--r--
2024-09-07 00:11
test_urlparse.py
70.38
KB
-rw-r--r--
2024-09-07 00:11
test_userdict.py
7.64
KB
-rw-r--r--
2024-09-07 00:11
test_userlist.py
1.97
KB
-rw-r--r--
2024-09-07 00:11
test_userstring.py
2.4
KB
-rw-r--r--
2024-09-07 00:11
test_utf8_mode.py
9.22
KB
-rw-r--r--
2024-09-07 00:11
test_utf8source.py
1.15
KB
-rw-r--r--
2024-09-07 00:11
test_uu.py
8.83
KB
-rw-r--r--
2024-09-07 00:11
test_uuid.py
35.74
KB
-rw-r--r--
2024-09-07 00:11
test_venv.py
20.46
KB
-rw-r--r--
2024-09-07 00:11
test_wait3.py
1.16
KB
-rw-r--r--
2024-09-07 00:11
test_wait4.py
1.15
KB
-rw-r--r--
2024-09-07 00:11
test_wave.py
6.57
KB
-rw-r--r--
2024-09-07 00:11
test_weakref.py
69.47
KB
-rw-r--r--
2024-09-07 00:11
test_weakset.py
15.03
KB
-rw-r--r--
2024-09-07 00:11
test_webbrowser.py
10.47
KB
-rw-r--r--
2024-09-07 00:11
test_winconsoleio.py
6.14
KB
-rw-r--r--
2024-09-07 00:11
test_winreg.py
21.38
KB
-rw-r--r--
2024-09-07 00:11
test_winsound.py
4.57
KB
-rw-r--r--
2024-09-07 00:11
test_with.py
25.78
KB
-rw-r--r--
2024-09-07 00:11
test_wsgiref.py
30.1
KB
-rw-r--r--
2024-09-07 00:11
test_xdrlib.py
2.17
KB
-rw-r--r--
2024-09-07 00:11
test_xml_dom_minicompat.py
4.18
KB
-rw-r--r--
2024-09-07 00:11
test_xml_etree.py
148.4
KB
-rw-r--r--
2024-09-23 14:45
test_xml_etree_c.py
8.06
KB
-rw-r--r--
2024-09-07 00:11
test_xmlrpc.py
56.34
KB
-rw-r--r--
2024-09-07 00:11
test_xmlrpc_net.py
1015
B
-rw-r--r--
2024-09-07 00:11
test_xxtestfuzz.py
670
B
-rw-r--r--
2024-09-07 00:11
test_yield_from.py
30.01
KB
-rw-r--r--
2024-09-07 00:11
test_zipapp.py
15.92
KB
-rw-r--r--
2024-09-07 00:11
test_zipfile.py
121.05
KB
-rw-r--r--
2024-09-07 00:11
test_zipfile64.py
5.8
KB
-rw-r--r--
2024-09-07 00:11
test_zipimport.py
29.28
KB
-rw-r--r--
2024-09-07 00:11
test_zipimport_support.py
10.44
KB
-rw-r--r--
2024-09-07 00:11
test_zlib.py
34.54
KB
-rw-r--r--
2024-09-07 00:11
testcodec.py
1.02
KB
-rw-r--r--
2024-09-07 00:11
testtar.tar
425
KB
-rw-r--r--
2024-09-07 00:11
tf_inherit_check.py
714
B
-rw-r--r--
2024-09-07 00:11
threaded_import_hangers.py
1.45
KB
-rw-r--r--
2024-09-07 00:11
time_hashlib.py
2.87
KB
-rw-r--r--
2024-09-07 00:11
tokenize_tests-latin1-coding-cookie-and-utf8-bom-sig.txt
443
B
-rw-r--r--
2024-09-07 00:11
tokenize_tests-no-coding-cookie-and-utf8-bom-sig-only.txt
302
B
-rw-r--r--
2024-09-07 00:11
tokenize_tests-utf8-coding-cookie-and-no-utf8-bom-sig.txt
421
B
-rw-r--r--
2024-09-07 00:11
tokenize_tests-utf8-coding-cookie-and-utf8-bom-sig.txt
326
B
-rw-r--r--
2024-09-07 00:11
tokenize_tests.txt
2.65
KB
-rw-r--r--
2024-09-07 00:11
win_console_handler.py
1.38
KB
-rw-r--r--
2024-09-07 00:11
xmltests.py
499
B
-rw-r--r--
2024-09-07 00:11
zip_cp437_header.zip
270
B
-rw-r--r--
2024-09-07 00:11
zipdir.zip
374
B
-rw-r--r--
2024-09-07 00:11
Save
Rename
"""Unit tests for memory-based file-like objects. StringIO -- for unicode strings BytesIO -- for bytes """ import unittest from test import support import io import _pyio as pyio import pickle import sys class IntLike: def __init__(self, num): self._num = num def __index__(self): return self._num __int__ = __index__ class MemorySeekTestMixin: def testInit(self): buf = self.buftype("1234567890") bytesIo = self.ioclass(buf) def testRead(self): buf = self.buftype("1234567890") bytesIo = self.ioclass(buf) self.assertEqual(buf[:1], bytesIo.read(1)) self.assertEqual(buf[1:5], bytesIo.read(4)) self.assertEqual(buf[5:], bytesIo.read(900)) self.assertEqual(self.EOF, bytesIo.read()) def testReadNoArgs(self): buf = self.buftype("1234567890") bytesIo = self.ioclass(buf) self.assertEqual(buf, bytesIo.read()) self.assertEqual(self.EOF, bytesIo.read()) def testSeek(self): buf = self.buftype("1234567890") bytesIo = self.ioclass(buf) bytesIo.read(5) bytesIo.seek(0) self.assertEqual(buf, bytesIo.read()) bytesIo.seek(3) self.assertEqual(buf[3:], bytesIo.read()) self.assertRaises(TypeError, bytesIo.seek, 0.0) def testTell(self): buf = self.buftype("1234567890") bytesIo = self.ioclass(buf) self.assertEqual(0, bytesIo.tell()) bytesIo.seek(5) self.assertEqual(5, bytesIo.tell()) bytesIo.seek(10000) self.assertEqual(10000, bytesIo.tell()) class MemoryTestMixin: def test_detach(self): buf = self.ioclass() self.assertRaises(self.UnsupportedOperation, buf.detach) def write_ops(self, f, t): self.assertEqual(f.write(t("blah.")), 5) self.assertEqual(f.seek(0), 0) self.assertEqual(f.write(t("Hello.")), 6) self.assertEqual(f.tell(), 6) self.assertEqual(f.seek(5), 5) self.assertEqual(f.tell(), 5) self.assertEqual(f.write(t(" world\n\n\n")), 9) self.assertEqual(f.seek(0), 0) self.assertEqual(f.write(t("h")), 1) self.assertEqual(f.truncate(12), 12) self.assertEqual(f.tell(), 1) def test_write(self): buf = self.buftype("hello world\n") memio = self.ioclass(buf) self.write_ops(memio, self.buftype) self.assertEqual(memio.getvalue(), buf) memio = self.ioclass() self.write_ops(memio, self.buftype) self.assertEqual(memio.getvalue(), buf) self.assertRaises(TypeError, memio.write, None) memio.close() self.assertRaises(ValueError, memio.write, self.buftype("")) def test_writelines(self): buf = self.buftype("1234567890") memio = self.ioclass() self.assertEqual(memio.writelines([buf] * 100), None) self.assertEqual(memio.getvalue(), buf * 100) memio.writelines([]) self.assertEqual(memio.getvalue(), buf * 100) memio = self.ioclass() self.assertRaises(TypeError, memio.writelines, [buf] + [1]) self.assertEqual(memio.getvalue(), buf) self.assertRaises(TypeError, memio.writelines, None) memio.close() self.assertRaises(ValueError, memio.writelines, []) def test_writelines_error(self): memio = self.ioclass() def error_gen(): yield self.buftype('spam') raise KeyboardInterrupt self.assertRaises(KeyboardInterrupt, memio.writelines, error_gen()) def test_truncate(self): buf = self.buftype("1234567890") memio = self.ioclass(buf) self.assertRaises(ValueError, memio.truncate, -1) self.assertRaises(ValueError, memio.truncate, IntLike(-1)) memio.seek(6) self.assertEqual(memio.truncate(IntLike(8)), 8) self.assertEqual(memio.getvalue(), buf[:8]) self.assertEqual(memio.truncate(), 6) self.assertEqual(memio.getvalue(), buf[:6]) self.assertEqual(memio.truncate(4), 4) self.assertEqual(memio.getvalue(), buf[:4]) self.assertEqual(memio.tell(), 6) memio.seek(0, 2) memio.write(buf) self.assertEqual(memio.getvalue(), buf[:4] + buf) pos = memio.tell() self.assertEqual(memio.truncate(None), pos) self.assertEqual(memio.tell(), pos) self.assertRaises(TypeError, memio.truncate, '0') memio.close() self.assertRaises(ValueError, memio.truncate, 0) self.assertRaises(ValueError, memio.truncate, IntLike(0)) def test_init(self): buf = self.buftype("1234567890") memio = self.ioclass(buf) self.assertEqual(memio.getvalue(), buf) memio = self.ioclass(None) self.assertEqual(memio.getvalue(), self.EOF) memio.__init__(buf * 2) self.assertEqual(memio.getvalue(), buf * 2) memio.__init__(buf) self.assertEqual(memio.getvalue(), buf) self.assertRaises(TypeError, memio.__init__, []) def test_read(self): buf = self.buftype("1234567890") memio = self.ioclass(buf) self.assertEqual(memio.read(0), self.EOF) self.assertEqual(memio.read(1), buf[:1]) self.assertEqual(memio.read(4), buf[1:5]) self.assertEqual(memio.read(900), buf[5:]) self.assertEqual(memio.read(), self.EOF) memio.seek(0) self.assertEqual(memio.read(IntLike(0)), self.EOF) self.assertEqual(memio.read(IntLike(1)), buf[:1]) self.assertEqual(memio.read(IntLike(4)), buf[1:5]) self.assertEqual(memio.read(IntLike(900)), buf[5:]) memio.seek(0) self.assertEqual(memio.read(), buf) self.assertEqual(memio.read(), self.EOF) self.assertEqual(memio.tell(), 10) memio.seek(0) self.assertEqual(memio.read(-1), buf) memio.seek(0) self.assertEqual(memio.read(IntLike(-1)), buf) memio.seek(0) self.assertEqual(type(memio.read()), type(buf)) memio.seek(100) self.assertEqual(type(memio.read()), type(buf)) memio.seek(0) self.assertEqual(memio.read(None), buf) self.assertRaises(TypeError, memio.read, '') memio.seek(len(buf) + 1) self.assertEqual(memio.read(1), self.EOF) memio.seek(len(buf) + 1) self.assertEqual(memio.read(IntLike(1)), self.EOF) memio.seek(len(buf) + 1) self.assertEqual(memio.read(), self.EOF) memio.close() self.assertRaises(ValueError, memio.read) def test_readline(self): buf = self.buftype("1234567890\n") memio = self.ioclass(buf * 2) self.assertEqual(memio.readline(0), self.EOF) self.assertEqual(memio.readline(IntLike(0)), self.EOF) self.assertEqual(memio.readline(), buf) self.assertEqual(memio.readline(), buf) self.assertEqual(memio.readline(), self.EOF) memio.seek(0) self.assertEqual(memio.readline(5), buf[:5]) self.assertEqual(memio.readline(5), buf[5:10]) self.assertEqual(memio.readline(5), buf[10:15]) memio.seek(0) self.assertEqual(memio.readline(IntLike(5)), buf[:5]) self.assertEqual(memio.readline(IntLike(5)), buf[5:10]) self.assertEqual(memio.readline(IntLike(5)), buf[10:15]) memio.seek(0) self.assertEqual(memio.readline(-1), buf) memio.seek(0) self.assertEqual(memio.readline(IntLike(-1)), buf) memio.seek(0) self.assertEqual(memio.readline(0), self.EOF) self.assertEqual(memio.readline(IntLike(0)), self.EOF) # Issue #24989: Buffer overread memio.seek(len(buf) * 2 + 1) self.assertEqual(memio.readline(), self.EOF) buf = self.buftype("1234567890\n") memio = self.ioclass((buf * 3)[:-1]) self.assertEqual(memio.readline(), buf) self.assertEqual(memio.readline(), buf) self.assertEqual(memio.readline(), buf[:-1]) self.assertEqual(memio.readline(), self.EOF) memio.seek(0) self.assertEqual(type(memio.readline()), type(buf)) self.assertEqual(memio.readline(), buf) self.assertRaises(TypeError, memio.readline, '') memio.close() self.assertRaises(ValueError, memio.readline) def test_readlines(self): buf = self.buftype("1234567890\n") memio = self.ioclass(buf * 10) self.assertEqual(memio.readlines(), [buf] * 10) memio.seek(5) self.assertEqual(memio.readlines(), [buf[5:]] + [buf] * 9) memio.seek(0) self.assertEqual(memio.readlines(15), [buf] * 2) memio.seek(0) self.assertEqual(memio.readlines(-1), [buf] * 10) memio.seek(0) self.assertEqual(memio.readlines(0), [buf] * 10) memio.seek(0) self.assertEqual(type(memio.readlines()[0]), type(buf)) memio.seek(0) self.assertEqual(memio.readlines(None), [buf] * 10) self.assertRaises(TypeError, memio.readlines, '') # Issue #24989: Buffer overread memio.seek(len(buf) * 10 + 1) self.assertEqual(memio.readlines(), []) memio.close() self.assertRaises(ValueError, memio.readlines) def test_iterator(self): buf = self.buftype("1234567890\n") memio = self.ioclass(buf * 10) self.assertEqual(iter(memio), memio) self.assertTrue(hasattr(memio, '__iter__')) self.assertTrue(hasattr(memio, '__next__')) i = 0 for line in memio: self.assertEqual(line, buf) i += 1 self.assertEqual(i, 10) memio.seek(0) i = 0 for line in memio: self.assertEqual(line, buf) i += 1 self.assertEqual(i, 10) # Issue #24989: Buffer overread memio.seek(len(buf) * 10 + 1) self.assertEqual(list(memio), []) memio = self.ioclass(buf * 2) memio.close() self.assertRaises(ValueError, memio.__next__) def test_getvalue(self): buf = self.buftype("1234567890") memio = self.ioclass(buf) self.assertEqual(memio.getvalue(), buf) memio.read() self.assertEqual(memio.getvalue(), buf) self.assertEqual(type(memio.getvalue()), type(buf)) memio = self.ioclass(buf * 1000) self.assertEqual(memio.getvalue()[-3:], self.buftype("890")) memio = self.ioclass(buf) memio.close() self.assertRaises(ValueError, memio.getvalue) def test_seek(self): buf = self.buftype("1234567890") memio = self.ioclass(buf) memio.read(5) self.assertRaises(ValueError, memio.seek, -1) self.assertRaises(ValueError, memio.seek, 1, -1) self.assertRaises(ValueError, memio.seek, 1, 3) self.assertEqual(memio.seek(0), 0) self.assertEqual(memio.seek(0, 0), 0) self.assertEqual(memio.read(), buf) self.assertEqual(memio.seek(3), 3) self.assertEqual(memio.seek(0, 1), 3) self.assertEqual(memio.read(), buf[3:]) self.assertEqual(memio.seek(len(buf)), len(buf)) self.assertEqual(memio.read(), self.EOF) memio.seek(len(buf) + 1) self.assertEqual(memio.read(), self.EOF) self.assertEqual(memio.seek(0, 2), len(buf)) self.assertEqual(memio.read(), self.EOF) memio.close() self.assertRaises(ValueError, memio.seek, 0) def test_overseek(self): buf = self.buftype("1234567890") memio = self.ioclass(buf) self.assertEqual(memio.seek(len(buf) + 1), 11) self.assertEqual(memio.read(), self.EOF) self.assertEqual(memio.tell(), 11) self.assertEqual(memio.getvalue(), buf) memio.write(self.EOF) self.assertEqual(memio.getvalue(), buf) memio.write(buf) self.assertEqual(memio.getvalue(), buf + self.buftype('\0') + buf) def test_tell(self): buf = self.buftype("1234567890") memio = self.ioclass(buf) self.assertEqual(memio.tell(), 0) memio.seek(5) self.assertEqual(memio.tell(), 5) memio.seek(10000) self.assertEqual(memio.tell(), 10000) memio.close() self.assertRaises(ValueError, memio.tell) def test_flush(self): buf = self.buftype("1234567890") memio = self.ioclass(buf) self.assertEqual(memio.flush(), None) def test_flags(self): memio = self.ioclass() self.assertEqual(memio.writable(), True) self.assertEqual(memio.readable(), True) self.assertEqual(memio.seekable(), True) self.assertEqual(memio.isatty(), False) self.assertEqual(memio.closed, False) memio.close() self.assertRaises(ValueError, memio.writable) self.assertRaises(ValueError, memio.readable) self.assertRaises(ValueError, memio.seekable) self.assertRaises(ValueError, memio.isatty) self.assertEqual(memio.closed, True) def test_subclassing(self): buf = self.buftype("1234567890") def test1(): class MemIO(self.ioclass): pass m = MemIO(buf) return m.getvalue() def test2(): class MemIO(self.ioclass): def __init__(me, a, b): self.ioclass.__init__(me, a) m = MemIO(buf, None) return m.getvalue() self.assertEqual(test1(), buf) self.assertEqual(test2(), buf) def test_instance_dict_leak(self): # Test case for issue #6242. # This will be caught by regrtest.py -R if this leak. for _ in range(100): memio = self.ioclass() memio.foo = 1 def test_pickling(self): buf = self.buftype("1234567890") memio = self.ioclass(buf) memio.foo = 42 memio.seek(2) class PickleTestMemIO(self.ioclass): def __init__(me, initvalue, foo): self.ioclass.__init__(me, initvalue) me.foo = foo # __getnewargs__ is undefined on purpose. This checks that PEP 307 # is used to provide pickling support. # Pickle expects the class to be on the module level. Here we use a # little hack to allow the PickleTestMemIO class to derive from # self.ioclass without having to define all combinations explicitly on # the module-level. import __main__ PickleTestMemIO.__module__ = '__main__' PickleTestMemIO.__qualname__ = PickleTestMemIO.__name__ __main__.PickleTestMemIO = PickleTestMemIO submemio = PickleTestMemIO(buf, 80) submemio.seek(2) # We only support pickle protocol 2 and onward since we use extended # __reduce__ API of PEP 307 to provide pickling support. for proto in range(2, pickle.HIGHEST_PROTOCOL + 1): for obj in (memio, submemio): obj2 = pickle.loads(pickle.dumps(obj, protocol=proto)) self.assertEqual(obj.getvalue(), obj2.getvalue()) self.assertEqual(obj.__class__, obj2.__class__) self.assertEqual(obj.foo, obj2.foo) self.assertEqual(obj.tell(), obj2.tell()) obj2.close() self.assertRaises(ValueError, pickle.dumps, obj2, proto) del __main__.PickleTestMemIO class PyBytesIOTest(MemoryTestMixin, MemorySeekTestMixin, unittest.TestCase): # Test _pyio.BytesIO; class also inherited for testing C implementation UnsupportedOperation = pyio.UnsupportedOperation @staticmethod def buftype(s): return s.encode("ascii") ioclass = pyio.BytesIO EOF = b"" def test_getbuffer(self): memio = self.ioclass(b"1234567890") buf = memio.getbuffer() self.assertEqual(bytes(buf), b"1234567890") memio.seek(5) buf = memio.getbuffer() self.assertEqual(bytes(buf), b"1234567890") # Trying to change the size of the BytesIO while a buffer is exported # raises a BufferError. self.assertRaises(BufferError, memio.write, b'x' * 100) self.assertRaises(BufferError, memio.truncate) self.assertRaises(BufferError, memio.close) self.assertFalse(memio.closed) # Mutating the buffer updates the BytesIO buf[3:6] = b"abc" self.assertEqual(bytes(buf), b"123abc7890") self.assertEqual(memio.getvalue(), b"123abc7890") # After the buffer gets released, we can resize and close the BytesIO # again del buf support.gc_collect() memio.truncate() memio.close() self.assertRaises(ValueError, memio.getbuffer) def test_read1(self): buf = self.buftype("1234567890") self.assertEqual(self.ioclass(buf).read1(), buf) self.assertEqual(self.ioclass(buf).read1(-1), buf) def test_readinto(self): buf = self.buftype("1234567890") memio = self.ioclass(buf) b = bytearray(b"hello") self.assertEqual(memio.readinto(b), 5) self.assertEqual(b, b"12345") self.assertEqual(memio.readinto(b), 5) self.assertEqual(b, b"67890") self.assertEqual(memio.readinto(b), 0) self.assertEqual(b, b"67890") b = bytearray(b"hello world") memio.seek(0) self.assertEqual(memio.readinto(b), 10) self.assertEqual(b, b"1234567890d") b = bytearray(b"") memio.seek(0) self.assertEqual(memio.readinto(b), 0) self.assertEqual(b, b"") self.assertRaises(TypeError, memio.readinto, '') import array a = array.array('b', b"hello world") memio = self.ioclass(buf) memio.readinto(a) self.assertEqual(a.tobytes(), b"1234567890d") memio.close() self.assertRaises(ValueError, memio.readinto, b) memio = self.ioclass(b"123") b = bytearray() memio.seek(42) memio.readinto(b) self.assertEqual(b, b"") def test_relative_seek(self): buf = self.buftype("1234567890") memio = self.ioclass(buf) self.assertEqual(memio.seek(-1, 1), 0) self.assertEqual(memio.seek(3, 1), 3) self.assertEqual(memio.seek(-4, 1), 0) self.assertEqual(memio.seek(-1, 2), 9) self.assertEqual(memio.seek(1, 1), 10) self.assertEqual(memio.seek(1, 2), 11) memio.seek(-3, 2) self.assertEqual(memio.read(), buf[-3:]) memio.seek(0) memio.seek(1, 1) self.assertEqual(memio.read(), buf[1:]) def test_unicode(self): memio = self.ioclass() self.assertRaises(TypeError, self.ioclass, "1234567890") self.assertRaises(TypeError, memio.write, "1234567890") self.assertRaises(TypeError, memio.writelines, ["1234567890"]) def test_bytes_array(self): buf = b"1234567890" import array a = array.array('b', list(buf)) memio = self.ioclass(a) self.assertEqual(memio.getvalue(), buf) self.assertEqual(memio.write(a), 10) self.assertEqual(memio.getvalue(), buf) def test_issue5449(self): buf = self.buftype("1234567890") self.ioclass(initial_bytes=buf) self.assertRaises(TypeError, self.ioclass, buf, foo=None) class TextIOTestMixin: def test_newlines_property(self): memio = self.ioclass(newline=None) # The C StringIO decodes newlines in write() calls, but the Python # implementation only does when reading. This function forces them to # be decoded for testing. def force_decode(): memio.seek(0) memio.read() self.assertEqual(memio.newlines, None) memio.write("a\n") force_decode() self.assertEqual(memio.newlines, "\n") memio.write("b\r\n") force_decode() self.assertEqual(memio.newlines, ("\n", "\r\n")) memio.write("c\rd") force_decode() self.assertEqual(memio.newlines, ("\r", "\n", "\r\n")) def test_relative_seek(self): memio = self.ioclass() self.assertRaises(OSError, memio.seek, -1, 1) self.assertRaises(OSError, memio.seek, 3, 1) self.assertRaises(OSError, memio.seek, -3, 1) self.assertRaises(OSError, memio.seek, -1, 2) self.assertRaises(OSError, memio.seek, 1, 1) self.assertRaises(OSError, memio.seek, 1, 2) def test_textio_properties(self): memio = self.ioclass() # These are just dummy values but we nevertheless check them for fear # of unexpected breakage. self.assertIsNone(memio.encoding) self.assertIsNone(memio.errors) self.assertFalse(memio.line_buffering) def test_newline_default(self): memio = self.ioclass("a\nb\r\nc\rd") self.assertEqual(list(memio), ["a\n", "b\r\n", "c\rd"]) self.assertEqual(memio.getvalue(), "a\nb\r\nc\rd") memio = self.ioclass() self.assertEqual(memio.write("a\nb\r\nc\rd"), 8) memio.seek(0) self.assertEqual(list(memio), ["a\n", "b\r\n", "c\rd"]) self.assertEqual(memio.getvalue(), "a\nb\r\nc\rd") def test_newline_none(self): # newline=None memio = self.ioclass("a\nb\r\nc\rd", newline=None) self.assertEqual(list(memio), ["a\n", "b\n", "c\n", "d"]) memio.seek(0) self.assertEqual(memio.read(1), "a") self.assertEqual(memio.read(2), "\nb") self.assertEqual(memio.read(2), "\nc") self.assertEqual(memio.read(1), "\n") self.assertEqual(memio.getvalue(), "a\nb\nc\nd") memio = self.ioclass(newline=None) self.assertEqual(2, memio.write("a\n")) self.assertEqual(3, memio.write("b\r\n")) self.assertEqual(3, memio.write("c\rd")) memio.seek(0) self.assertEqual(memio.read(), "a\nb\nc\nd") self.assertEqual(memio.getvalue(), "a\nb\nc\nd") memio = self.ioclass("a\r\nb", newline=None) self.assertEqual(memio.read(3), "a\nb") def test_newline_empty(self): # newline="" memio = self.ioclass("a\nb\r\nc\rd", newline="") self.assertEqual(list(memio), ["a\n", "b\r\n", "c\r", "d"]) memio.seek(0) self.assertEqual(memio.read(4), "a\nb\r") self.assertEqual(memio.read(2), "\nc") self.assertEqual(memio.read(1), "\r") self.assertEqual(memio.getvalue(), "a\nb\r\nc\rd") memio = self.ioclass(newline="") self.assertEqual(2, memio.write("a\n")) self.assertEqual(2, memio.write("b\r")) self.assertEqual(2, memio.write("\nc")) self.assertEqual(2, memio.write("\rd")) memio.seek(0) self.assertEqual(list(memio), ["a\n", "b\r\n", "c\r", "d"]) self.assertEqual(memio.getvalue(), "a\nb\r\nc\rd") def test_newline_lf(self): # newline="\n" memio = self.ioclass("a\nb\r\nc\rd", newline="\n") self.assertEqual(list(memio), ["a\n", "b\r\n", "c\rd"]) self.assertEqual(memio.getvalue(), "a\nb\r\nc\rd") memio = self.ioclass(newline="\n") self.assertEqual(memio.write("a\nb\r\nc\rd"), 8) memio.seek(0) self.assertEqual(list(memio), ["a\n", "b\r\n", "c\rd"]) self.assertEqual(memio.getvalue(), "a\nb\r\nc\rd") def test_newline_cr(self): # newline="\r" memio = self.ioclass("a\nb\r\nc\rd", newline="\r") self.assertEqual(memio.read(), "a\rb\r\rc\rd") memio.seek(0) self.assertEqual(list(memio), ["a\r", "b\r", "\r", "c\r", "d"]) self.assertEqual(memio.getvalue(), "a\rb\r\rc\rd") memio = self.ioclass(newline="\r") self.assertEqual(memio.write("a\nb\r\nc\rd"), 8) memio.seek(0) self.assertEqual(list(memio), ["a\r", "b\r", "\r", "c\r", "d"]) memio.seek(0) self.assertEqual(memio.readlines(), ["a\r", "b\r", "\r", "c\r", "d"]) self.assertEqual(memio.getvalue(), "a\rb\r\rc\rd") def test_newline_crlf(self): # newline="\r\n" memio = self.ioclass("a\nb\r\nc\rd", newline="\r\n") self.assertEqual(memio.read(), "a\r\nb\r\r\nc\rd") memio.seek(0) self.assertEqual(list(memio), ["a\r\n", "b\r\r\n", "c\rd"]) memio.seek(0) self.assertEqual(memio.readlines(), ["a\r\n", "b\r\r\n", "c\rd"]) self.assertEqual(memio.getvalue(), "a\r\nb\r\r\nc\rd") memio = self.ioclass(newline="\r\n") self.assertEqual(memio.write("a\nb\r\nc\rd"), 8) memio.seek(0) self.assertEqual(list(memio), ["a\r\n", "b\r\r\n", "c\rd"]) self.assertEqual(memio.getvalue(), "a\r\nb\r\r\nc\rd") def test_issue5265(self): # StringIO can duplicate newlines in universal newlines mode memio = self.ioclass("a\r\nb\r\n", newline=None) self.assertEqual(memio.read(5), "a\nb\n") self.assertEqual(memio.getvalue(), "a\nb\n") def test_newline_argument(self): self.assertRaises(TypeError, self.ioclass, newline=b"\n") self.assertRaises(ValueError, self.ioclass, newline="error") # These should not raise an error for newline in (None, "", "\n", "\r", "\r\n"): self.ioclass(newline=newline) class PyStringIOTest(MemoryTestMixin, MemorySeekTestMixin, TextIOTestMixin, unittest.TestCase): buftype = str ioclass = pyio.StringIO UnsupportedOperation = pyio.UnsupportedOperation EOF = "" def test_lone_surrogates(self): # Issue #20424 memio = self.ioclass('\ud800') self.assertEqual(memio.read(), '\ud800') memio = self.ioclass() memio.write('\ud800') self.assertEqual(memio.getvalue(), '\ud800') class PyStringIOPickleTest(TextIOTestMixin, unittest.TestCase): """Test if pickle restores properly the internal state of StringIO. """ buftype = str UnsupportedOperation = pyio.UnsupportedOperation EOF = "" class ioclass(pyio.StringIO): def __new__(cls, *args, **kwargs): return pickle.loads(pickle.dumps(pyio.StringIO(*args, **kwargs))) def __init__(self, *args, **kwargs): pass class CBytesIOTest(PyBytesIOTest): ioclass = io.BytesIO UnsupportedOperation = io.UnsupportedOperation def test_getstate(self): memio = self.ioclass() state = memio.__getstate__() self.assertEqual(len(state), 3) bytearray(state[0]) # Check if state[0] supports the buffer interface. self.assertIsInstance(state[1], int) if state[2] is not None: self.assertIsInstance(state[2], dict) memio.close() self.assertRaises(ValueError, memio.__getstate__) def test_setstate(self): # This checks whether __setstate__ does proper input validation. memio = self.ioclass() memio.__setstate__((b"no error", 0, None)) memio.__setstate__((bytearray(b"no error"), 0, None)) memio.__setstate__((b"no error", 0, {'spam': 3})) self.assertRaises(ValueError, memio.__setstate__, (b"", -1, None)) self.assertRaises(TypeError, memio.__setstate__, ("unicode", 0, None)) self.assertRaises(TypeError, memio.__setstate__, (b"", 0.0, None)) self.assertRaises(TypeError, memio.__setstate__, (b"", 0, 0)) self.assertRaises(TypeError, memio.__setstate__, (b"len-test", 0)) self.assertRaises(TypeError, memio.__setstate__) self.assertRaises(TypeError, memio.__setstate__, 0) memio.close() self.assertRaises(ValueError, memio.__setstate__, (b"closed", 0, None)) check_sizeof = support.check_sizeof @support.cpython_only def test_sizeof(self): basesize = support.calcobjsize('P2n2Pn') check = self.check_sizeof self.assertEqual(object.__sizeof__(io.BytesIO()), basesize) check(io.BytesIO(), basesize ) n = 1000 # use a variable to prevent constant folding check(io.BytesIO(b'a' * n), basesize + sys.getsizeof(b'a' * n)) # Various tests of copy-on-write behaviour for BytesIO. def _test_cow_mutation(self, mutation): # Common code for all BytesIO copy-on-write mutation tests. imm = b' ' * 1024 old_rc = sys.getrefcount(imm) memio = self.ioclass(imm) self.assertEqual(sys.getrefcount(imm), old_rc + 1) mutation(memio) self.assertEqual(sys.getrefcount(imm), old_rc) @support.cpython_only def test_cow_truncate(self): # Ensure truncate causes a copy. def mutation(memio): memio.truncate(1) self._test_cow_mutation(mutation) @support.cpython_only def test_cow_write(self): # Ensure write that would not cause a resize still results in a copy. def mutation(memio): memio.seek(0) memio.write(b'foo') self._test_cow_mutation(mutation) @support.cpython_only def test_cow_setstate(self): # __setstate__ should cause buffer to be released. memio = self.ioclass(b'foooooo') state = memio.__getstate__() def mutation(memio): memio.__setstate__(state) self._test_cow_mutation(mutation) @support.cpython_only def test_cow_mutable(self): # BytesIO should accept only Bytes for copy-on-write sharing, since # arbitrary buffer-exporting objects like bytearray() aren't guaranteed # to be immutable. ba = bytearray(1024) old_rc = sys.getrefcount(ba) memio = self.ioclass(ba) self.assertEqual(sys.getrefcount(ba), old_rc) class CStringIOTest(PyStringIOTest): ioclass = io.StringIO UnsupportedOperation = io.UnsupportedOperation # XXX: For the Python version of io.StringIO, this is highly # dependent on the encoding used for the underlying buffer. def test_widechar(self): buf = self.buftype("\U0002030a\U00020347") memio = self.ioclass(buf) self.assertEqual(memio.getvalue(), buf) self.assertEqual(memio.write(buf), len(buf)) self.assertEqual(memio.tell(), len(buf)) self.assertEqual(memio.getvalue(), buf) self.assertEqual(memio.write(buf), len(buf)) self.assertEqual(memio.tell(), len(buf) * 2) self.assertEqual(memio.getvalue(), buf + buf) def test_getstate(self): memio = self.ioclass() state = memio.__getstate__() self.assertEqual(len(state), 4) self.assertIsInstance(state[0], str) self.assertIsInstance(state[1], str) self.assertIsInstance(state[2], int) if state[3] is not None: self.assertIsInstance(state[3], dict) memio.close() self.assertRaises(ValueError, memio.__getstate__) def test_setstate(self): # This checks whether __setstate__ does proper input validation. memio = self.ioclass() memio.__setstate__(("no error", "\n", 0, None)) memio.__setstate__(("no error", "", 0, {'spam': 3})) self.assertRaises(ValueError, memio.__setstate__, ("", "f", 0, None)) self.assertRaises(ValueError, memio.__setstate__, ("", "", -1, None)) self.assertRaises(TypeError, memio.__setstate__, (b"", "", 0, None)) self.assertRaises(TypeError, memio.__setstate__, ("", b"", 0, None)) self.assertRaises(TypeError, memio.__setstate__, ("", "", 0.0, None)) self.assertRaises(TypeError, memio.__setstate__, ("", "", 0, 0)) self.assertRaises(TypeError, memio.__setstate__, ("len-test", 0)) self.assertRaises(TypeError, memio.__setstate__) self.assertRaises(TypeError, memio.__setstate__, 0) memio.close() self.assertRaises(ValueError, memio.__setstate__, ("closed", "", 0, None)) class CStringIOPickleTest(PyStringIOPickleTest): UnsupportedOperation = io.UnsupportedOperation class ioclass(io.StringIO): def __new__(cls, *args, **kwargs): return pickle.loads(pickle.dumps(io.StringIO(*args, **kwargs))) def __init__(self, *args, **kwargs): pass if __name__ == '__main__': unittest.main()