annotate tck7/jtrlist.sh @ 3:e0c800ba69f7 draft

Added scripts for building JDKs and creating .jtr list for failed tests.
author Pavel Tisnovsky <ptisnovs@redhat.com>
date Thu, 03 Apr 2014 10:20:06 +0200
parents
children aa8fb6fa2243
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
3
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
1 #!/usr/bin/bash
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
2
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
3 # Daily test builder.
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
4 #
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
5 # Copyright (C) 2009, 2010, 2011, 2012, 2013, 2014 Red Hat
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
6 #
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
7 # This tool is free software; you can redistribute it and/or modify
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
8 # it under the terms of the GNU General Public License as published by
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
9 # the Free Software Foundation; either version 2, or (at your option)
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
10 # any later version.
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
11 #
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
12 # This tool is distributed in the hope that it will be useful, but
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
13 # WITHOUT ANY WARRANTY; without even the implied warranty of
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
15 # General Public License for more details.
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
16 #
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
17 # You should have received a copy of the GNU General Public License
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
18 # along with IcedTea; see the file COPYING. If not, write to the
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
19 # Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
20 # 02110-1301 USA.
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
21 #
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
22 # Linking this library statically or dynamically with other modules is
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
23 # making a combined work based on this library. Thus, the terms and
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
24 # conditions of the GNU General Public License cover the whole
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
25 # combination.
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
26 #
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
27 # As a special exception, the copyright holders of this library give you
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
28 # permission to link this library with independent modules to produce an
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
29 # executable, regardless of the license terms of these independent
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
30 # modules, and to copy and distribute the resulting executable under
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
31 # terms of your choice, provided that you also meet, for each linked
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
32 # independent module, the terms and conditions of the license of that
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
33 # module. An independent module is a module which is not derived from
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
34 # or based on this library. If you modify this library, you may extend
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
35 # this exception to your version of the library, but you are not
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
36 # obligated to do so. If you do not wish to do so, delete this
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
37 # exception statement from your version.
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
38 #
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
39 # Checks test results for any errors and stores .jtr files containing test report
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
40 # into the 'jtr' directory.
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
41 #
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
42 # Author: Pavel Tisnovsky
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
43 # e-mail: ptisnovs@redhat.com
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
44
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
45 TESTS="compiler devtools runtime"
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
46 DATE=`ls /jck/work`
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
47 RESULTDIR=/jck/results
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
48 WORKDIR=/jck/work
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
49 DESTDIR=jtr
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
50
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
51 for date in ${DATE}
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
52 do
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
53 echo "****${date}****"
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
54 for test in $TESTS; do
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
55 summary="${RESULTDIR}/${date}/${test}/text/summary.txt"
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
56 echo "Processing "$summary
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
57 # we need to translate this form of records:
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
58 # "api/java_applet/Applet/AccessibleApplet/index.html#Ctor"
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
59 # into:
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
60 # "api/java_applet/Applet/AccessibleApplet/index_Ctor.jtr"
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
61 #dirs=`grep " Failed\. test cases\| Error\. " $summary | sed -e 's/\.html.*//g;s/\(.*\)\/[^\/]*/\\1/g'`
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
62 #files=`grep " Failed\. test cases\| Error\. " $summary | sed -e 's/\.html//g;s/\#/_/g;s/ .*/\.jtr/g'`
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
63 dirs=`grep " Failed\. \| Error\. " $summary | sed -e 's/\.html.*//g;s/\(.*\)\/[^\/]*/\\1/g'`
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
64 files=`grep " Failed\. \| Error\. " $summary | sed -e 's/\.html//g;s/\#/_/g;s/ .*/\.jtr/g'`
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
65 for dir in $dirs; do
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
66 mkdir -p "${DESTDIR}/${date}/${test}/${dir}"
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
67 done
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
68 for file in $files; do
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
69 cp "${WORKDIR}/${date}/${test}/${file}" "${DESTDIR}/${date}/${test}/${file}"
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
70 echo $file
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
71 done
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
72 done
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
73 done
e0c800ba69f7 Added scripts for building JDKs and creating .jtr list for failed tests.
Pavel Tisnovsky <ptisnovs@redhat.com>
parents:
diff changeset
74