-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathruntests.py
executable file
·37 lines (29 loc) · 1008 Bytes
/
runtests.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#!/usr/bin/env python
import warnings
import selenosis
def main():
warnings.simplefilter("error", Warning)
warnings.filterwarnings("ignore", module="polymorphic")
warnings.filterwarnings("ignore", "use_for_related_fields")
try:
from django.utils.deprecation import RemovedInDjango40Warning
except ImportError:
pass
else:
warnings.filterwarnings("ignore", category=RemovedInDjango40Warning)
try:
from django.utils.deprecation import RemovedInDjango41Warning
except ImportError:
pass
else:
warnings.filterwarnings("ignore", category=RemovedInDjango41Warning)
# Introduced in Python 3.7
warnings.filterwarnings(
'ignore',
category=DeprecationWarning,
message="Using or importing the ABCs from 'collections' instead of from 'collections.abc'",
)
runtests = selenosis.RunTests("polymorphic_fk.tests.settings", "polymorphic_fk")
runtests()
if __name__ == '__main__':
main()