-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathruntests.py
32 lines (25 loc) · 881 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
# -*- coding: utf-8 -*-
# -----------------------------------------------------------------------------
# Copyright © Climate Data Preprocessing Tool Project Contributors
# https://github.com/cgq-qgc/climate-data-preprocessing-tool
#
# This file is part of Climate Data Preprocessing Tool.
# Licensed under the terms of the GNU General Public License.
# -----------------------------------------------------------------------------
"""
File for running tests programmatically.
"""
import os
os.environ['CDPREP_PYTEST'] = 'True'
import pytest
def main():
"""
Run pytest tests.
"""
errno = pytest.main(['-x', 'cdprep', '-v', '-rw', '--durations=10',
'--cov=cdprep', '-o', 'junit_family=xunit2',
'--no-coverage-upload'])
if errno != 0:
raise SystemExit(errno)
if __name__ == '__main__':
main()