-
Notifications
You must be signed in to change notification settings - Fork 17
/
runtests.py
67 lines (50 loc) · 1.94 KB
/
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
# -*- coding: ascii -*-
# ______ _ _ _____ _ _____ _ _ _
# | ____(_) | | __ \ | | / ____| (_) | |
# | |__ _| | ___| |__) |___ ___| | __ | | | |_ ___ _ __ | |_
# | __| | | |/ _ \ _ // _ \ / __| |/ / | | | | |/ _ \ '_ \| __|
# | | | | | __/ | \ \ (_) | (__| < | |____| | | __/ | | | |_
# |_| |_|_|\___|_| \_\___/ \___|_|\_\ \_____|_|_|\___|_| |_|\__|
#
# Copyright (C) 2012 Heyware s.r.l.
#
# This file is part of FileRock Client.
#
# FileRock Client is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# FileRock Client is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with FileRock Client. If not, see <http://www.gnu.org/licenses/>.
#
"""
Nose test runner
Any command line parameter given to this script will be passed to nose.
To selectivly run a package of tests you can do as follows:
# Run only tests in the test.unit package
python runtests.py -A "'tests.unit' in __module__"
# Run only tests in the test.integration package
python runtests.py -A "'tests.integration' in __module__"
----
This module is part of the FileRock Client.
Copyright (C) 2012 - Heyware s.r.l.
FileRock Client is licensed under GPLv3 License.
"""
import sys
import nose
argv = sys.argv
# Make the client code accessible to tests
#sys.path.append('..')
# Directory where to (recursively) look for tests
argv.append('--where=./tests/')
# Let me print stuff on stdout from tests
argv.append('--nocapture')
# Verbose output
argv.append('-v')
nose.run(argv=argv)