Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
d0558982
Commit
d0558982
authored
Mar 27, 2014
by
Yury Selivanov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
asyncio.tests: Autodiscover asyncio tests. Patch by Vajrasky Kok. Closes #20668
parent
3196dcda
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
12 deletions
+13
-12
Lib/test/test_asyncio/__init__.py
Lib/test/test_asyncio/__init__.py
+10
-12
Misc/NEWS
Misc/NEWS
+3
-0
No files found.
Lib/test/test_asyncio/__init__.py
View file @
d0558982
...
...
@@ -10,20 +10,18 @@ import_module('concurrent.futures')
def
suite
():
tests_file
=
os
.
path
.
join
(
os
.
path
.
dirname
(
__file__
),
'tests.txt'
)
with
open
(
tests_file
)
as
fp
:
test_names
=
fp
.
read
().
splitlines
()
tests
=
unittest
.
TestSuite
()
loader
=
unittest
.
TestLoader
()
for
test_name
in
test_names
:
mod_name
=
'test.'
+
test_name
try
:
__import__
(
mod_name
)
except
unittest
.
SkipTest
:
pass
else
:
mod
=
sys
.
modules
[
mod_name
]
tests
.
addTests
(
loader
.
loadTestsFromModule
(
mod
))
for
fn
in
os
.
listdir
(
os
.
path
.
dirname
(
__file__
)):
if
fn
.
startswith
(
"test"
)
and
fn
.
endswith
(
".py"
):
mod_name
=
'test.test_asyncio.'
+
fn
[:
-
3
]
try
:
__import__
(
mod_name
)
except
unittest
.
SkipTest
:
pass
else
:
mod
=
sys
.
modules
[
mod_name
]
tests
.
addTests
(
loader
.
loadTestsFromModule
(
mod
))
return
tests
...
...
Misc/NEWS
View file @
d0558982
...
...
@@ -107,6 +107,9 @@ Tests
redirect
of
http
://
www
.
python
.
org
/
to
https
://
www
.
python
.
org
:
use
http
://
www
.
example
.
com
instead
.
-
Issue
#
20668
:
asyncio
tests
no
longer
rely
on
tests
.
txt
file
.
(
Patch
by
Vajrasky
Kok
)
Tools
/
Demos
-----------
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment