mirrored from https://www.bouncycastle.org/repositories/bc-lts-java
-
Notifications
You must be signed in to change notification settings - Fork 8
/
all_test_unsigned.sh
executable file
·61 lines (41 loc) · 1.24 KB
/
all_test_unsigned.sh
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
#!/usr/bin/env bash
version=`fgrep version gradle.properties | sed -e "s/version=//"`
rm -rf mtest
mkdir mtest
artifactsHome=build/libs/
tj=( $artifactsHome/*tests.jar )
testJar="${tj[0]}";
prefixes=("bcprov-lts8on" "bcpkix-lts8on" "bctls-lts8on" "bcutil-lts8on" "bcpg-lts8on" "bcmail-lts8on" "bcpg-lts8on")
for str in "${prefixes[@]}"; do
src="jars/${str}-${version}.jar"
echo $src
cp "${src}" mtest/
done
a=(`$JAVA_HOME/bin/jar -tf "$testJar" | grep -E "AllTests\.class" | sed -e 's!.class!!' | sed -e 's|/|.|g'`);
rm -rf /tmp/bc-libs
mkdir /tmp/bc-libs
export DYLIB_LIBRARY_PATH=/tmp/bc-libs
export LD_LIBRARY_PATH=/tmp/bc-libs
java \
-cp "$testJar:mtest/*:libs/junit.jar:libs/activation.jar:libs/mail.jar" \
org.bouncycastle.util.DumpInfo
for i in "${a[@]}"
do
# case $i in org\.bouncycaslte\.crypto\.engines\.*)
# echo "skipping $i"
# continue
# esac
echo $i
java \
-cp "$testJar:mtest/*:libs/junit.jar:libs/activation.jar:libs/mail.jar" \
-Dbc.test.data.home=core/src/test/data \
"$i"
if [[ $? != 0 ]]; then
echo ""
echo "--------------------------------!!!"
echo "$i failed"
exit 1;
fi
echo "-------------------------------------"
echo ""
done