-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathperfcompare.sh
More file actions
executable file
·21 lines (15 loc) · 849 Bytes
/
perfcompare.sh
File metadata and controls
executable file
·21 lines (15 loc) · 849 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/bin/bash
BRANCH=t_ISPN-5019
function log() {
echo $(date +%H:%M:%S) $* | tee -a perfcompare.log
}
log "Starting perf comparison on branch $BRANCH"
#mvn clean install -DskipTests -am -pl core || exit $?
for c in $(git log --format=%H master..$BRANCH); do
log "Testing commit $c $(git log --format=%s -1 $c)"
git checkout $c
timeout 600 mvn clean install -pl core -DdefaultTestGroup=stress -DdefaultExcludedTestGroup= -Dtest=LargeClusterStressTest | tee >(grep 'Tests run: .* Time elapsed:' >> perfcompare.log) || exit $?
find core -name 'TEST-*.xml' | xargs grep "<testcase" | sed 's/.*<testcase.* name="\([^"]*\)" .*/\1 &/' | sed 's/.*<testcase.* classname="\([^"]*\)".*/\1 &/' | sed 's/.*<testcase.* time="\([^"]*\)".*/\1 &/' | sed 's/ <testcase.*//' | tee -a perfcompare.log
done
log "Perf comparison done"
git checkout $BRANCH