From d05ce9c61e5ca9051f2edad4702170c6e99702aa Mon Sep 17 00:00:00 2001 From: Eskil Abrahamsen Blomfeldt Date: Mon, 5 Aug 2013 09:52:14 +0200 Subject: Android: Enable script to run single autotest To make it easier to debug failures, adds the "testcase" commandline option, which takes the name of the test to run and then just runs this single test. Change-Id: Ib202bb2a5dac889b6691f9c4d0620b3e0941cf3d Reviewed-by: Paul Olav Tvete --- tests/auto/android/runtests.pl | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'tests/auto/android') diff --git a/tests/auto/android/runtests.pl b/tests/auto/android/runtests.pl index 35cadda498..55e1a224d8 100755 --- a/tests/auto/android/runtests.pl +++ b/tests/auto/android/runtests.pl @@ -79,6 +79,7 @@ GetOptions('h|help' => \$help , 'ant=s' => \$ant_tool , 'strip=s' => \$strip_tool , 'readelf=s' => \$readelf_tool + , 'testcase=s' => \$testcase ) or pod2usage(2); pod2usage(1) if $help; pod2usage(-verbose => 2) if $man; @@ -253,7 +254,14 @@ print "Building $tests_dir \n"; system("make distclean") if ($make_clean); system("$qmake_path CONFIG-=QTDIR_build -r") == 0 or die "Can't run qmake\n"; #exec qmake system("make -j$jobs") == 0 or warn "Can't build all tests\n"; #exec make -my $testsFiles=`find . -name libtst_*.so`; # only tests + +my $testsFiles = ""; +if ($testcase) { + $testsFiles=`find . -name libtst_$testcase.so`; # only tests +} else { + $testsFiles=`find . -name libtst_*.so`; # only tests +} + foreach (split("\n",$testsFiles)) { chomp; #remove white spaces -- cgit v1.2.3