forked from apache/tomcat
-
Notifications
You must be signed in to change notification settings - Fork 2
100 lines (72 loc) · 3.28 KB
/
main.yml
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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
name: tomcat-10.0.x-TT.x
on:
push:
branches:
- tomcat-10.0.x-TT.x
pull_request:
branches:
- tomcat-10.0.x-TT.x
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: setup jdk 11
uses: actions/setup-java@v1
with:
java-version: '11'
- name: donwload ant
run: curl https://archive.apache.org/dist/ant/binaries/apache-ant-1.10.13-bin.zip --output ant9.zip
- name: unzip ant 9
run: unzip -qq ant9.zip
- name: default os ant version to 1.10.13
run: sudo cp -a apache-ant-1.10.13/. $ANT_HOME
- name: download libraries
run: curl https://support-delivery.s3.amazonaws.com/tomcat7-build-libs.zip --output tomcat7-build-libs-.zip
- name: extract libs
run: unzip -qq tomcat7-build-libs-.zip -d /home/runner/
- name: ant_build
run: ant
- name: ant_test
run: ant test | true
env:
ANT_OPTS: -Xmx2G -XX:MaxPermSize=512m
- name: obtained_error_result
run: grep 'Caused an ERROR' output/build/logs/* > error_result.txt | true
- name: obtained_failed_result
run: grep 'FAILED' output/build/logs/* > failed_result.txt | true
- name: print_error
run: cat error_result.txt
- name: print_failed
run: cat failed_result.txt
- name: expected_error_and_failed_result
run: touch known_errors.txt && touch known_failed.txt
#Known ERRORS
- name: remove_known_error_1
run: sed -i.bak '/TEST-org.apache.catalina.valves.rewrite.TestResolverSSL/d' error_result.txt | true
- name: remove_known_error_2
run: sed -i.bak '/TEST-org.apache.coyote.http2.TestLargeUpload/d' error_result.txt | true
- name: remove_known_error_3
run: sed -i.bak '/TEST-org.apache.tomcat.util.net.TestClientCert/d' error_result.txt | true
- name: remove_known_error_4
run: sed -i.bak '/TEST-org.apache.tomcat.util.net.TestClientCertTls13/d' error_result.txt | true
- name: remove_known_error_5
run: sed -i.bak '/TEST-org.apache.tomcat.util.net.TestCustomSsl/d' error_result.txt | true
- name: remove_known_error_6
run: sed -i.bak '/TEST-org.apache.tomcat.websocket.TestWebSocketFrameClientSSL/d' error_result.txt | true
- name: remove_known_error_7
run: sed -i.bak '/TEST-org.apache.tomcat.websocket.TestWsWebSocketContainer/d' error_result.txt | true
- name: remove_known_error_8
run: sed -i.bak '/TEST-org.apache.tomcat.util.net.TestCustomSslTrustManager/d' error_result.txt | true
- name: remove_known_error_9
run: sed -i.bak '/TEST-org.apache.tomcat.util.net.TestSsl/d' error_result.txt | true
#Known FAILED
- name: remove_known_failed_1
run: sed -i.bak '/TEST-org.apache.tomcat.util.net.TestSsl/d' failed_result.txt | true
- name: remove_known_failed_2
run: sed -i.bak '/TEST-org.apache.tomcat.util.net.openssl.ciphers.TestCipher/d' failed_result.txt | true
- name: remove_known_failed_3
run: sed -i.bak '/TEST-org.apache.tomcat.util.net.openssl.ciphers.TestOpenSSLCipherConfigurationParser/d' failed_result.txt | true
- name: final_status
run: diff failed_result.txt known_failed.txt && diff error_result.txt known_errors.txt