forked from getavalon/core
-
Notifications
You must be signed in to change notification settings - Fork 0
/
run_maya_tests.py
56 lines (40 loc) · 1.17 KB
/
run_maya_tests.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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
"""Use Mayapy for testing
Usage:
$ mayapy run_maya_tests.py
"""
import sys
import nose
import logging
import warnings
from nose_exclude import NoseExclude
warnings.filterwarnings("ignore", category=DeprecationWarning)
if __name__ == "__main__":
from maya import standalone
standalone.initialize()
log = logging.getLogger()
# Discard default Maya logging handler
log.handlers[:] = []
argv = sys.argv[:]
argv.extend([
# Sometimes, files from Windows accessed
# from Linux cause the executable flag to be
# set, and Nose has an aversion to these
# per default.
"--exe",
"--verbose",
"--with-doctest",
"--with-coverage",
"--cover-html",
"--cover-tests",
"--cover-erase",
"--exclude-dir=avalon/nuke",
"--exclude-dir=avalon/houdini",
"--exclude-dir=avalon/schema",
# We can expect any vendors to
# be well tested beforehand.
"--exclude-dir=avalon/vendor",
# These are vendored and unmodified by Avalon
"--exclude-dir=avalon/style",
])
nose.main(argv=argv,
addplugins=[NoseExclude()])