~alecu/ubuntu-sso-client/timestamp-autofix-1-4

« back to all changes in this revision

Viewing changes to run-tests

  • Committer: Tarmac
  • Author(s): Natalia B. Bidart
  • Date: 2011-08-12 14:31:37 UTC
  • mfrom: (755.1.1 run-qt)
  • Revision ID: tarmac-20110812143137-dmqfwxveib2nbn5x
- Adding -qt option to test run script so QT tests can be run (LP: #825218).

Show diffs side-by-side

added added

removed removed

Lines of Context:
16
16
# You should have received a copy of the GNU General Public License along
17
17
# with this program.  If not, see <http://www.gnu.org/licenses/>.
18
18
 
 
19
QT_TESTS_PATH=ubuntu_sso/qt/tests
 
20
GTK_TESTS_PATH=ubuntu_sso/gtk/tests
 
21
 
19
22
set -e
20
23
 
 
24
if [ "$1" == "-qt" ]; then
 
25
    USE_QT=1
 
26
    shift
 
27
else
 
28
    USE_QT=0
 
29
fi
 
30
 
21
31
if [ $# -ne 0 ]; then
22
32
    # run specific module given by the caller
23
33
    MODULE="$@"
39
49
unset GTK_MODULES
40
50
 
41
51
echo "Running test suite for ""$MODULE"
42
 
`which xvfb-run` u1trial "$MODULE" -i "test_windows.py, test_qt_views.py"
 
52
if [ "$USE_QT" -eq 0 ]; then
 
53
    `which xvfb-run` u1trial -p "$QT_TESTS_PATH" -i "test_windows.py" "$MODULE"
 
54
else
 
55
    ./setup.py build
 
56
    `which xvfb-run` u1trial -p "$GTK_TESTS_PATH" -i "test_windows.py" --reactor=qt4 --gui "$MODULE"
 
57
fi
43
58
style_check
44
59
rm -rf _trial_temp
 
60
rm -rf build