Skip to content

Commit 1a456f9

Browse files
Merge pull request #2217 from bugsnag/tms/symbolicate
Upload symbol files when repeating test requests to Bugsnag instances
2 parents d306063 + e489cb0 commit 1a456f9

4 files changed

Lines changed: 54 additions & 6 deletions

File tree

.buildkite/pipeline.full.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,8 @@ steps:
6464
- "--aws-public-ip"
6565
- "--farm=bb"
6666
- "--device=ANDROID_9"
67+
- "--repeater-api-key="
68+
- "--hub-repeater-api-key="
6769
test-collector#v1.10.2:
6870
files: "reports/TEST-*.xml"
6971
format: "junit"
@@ -89,6 +91,8 @@ steps:
8991
- "--appium-version=1.22.0"
9092
- "--farm=bs"
9193
- "--device=ANDROID_9"
94+
- "--repeater-api-key="
95+
- "--hub-repeater-api-key="
9296
test-collector#v1.10.2:
9397
files: "reports/TEST-*.xml"
9498
format: "junit"
@@ -122,6 +126,8 @@ steps:
122126
- "--aws-public-ip"
123127
- "--farm=bb"
124128
- "--device=ANDROID_9"
129+
- "--repeater-api-key="
130+
- "--hub-repeater-api-key="
125131
test-collector#v1.10.2:
126132
files: "reports/TEST-*.xml"
127133
format: "junit"
@@ -151,6 +157,8 @@ steps:
151157
- "--appium-version=1.22.0"
152158
- "--farm=bs"
153159
- "--device=ANDROID_9"
160+
- "--repeater-api-key="
161+
- "--hub-repeater-api-key="
154162
test-collector#v1.10.2:
155163
files: "reports/TEST-*.xml"
156164
format: "junit"
@@ -186,6 +194,8 @@ steps:
186194
- "--device=ANDROID_7"
187195
- "--exclude=features/full_tests/[^a-k].*.feature"
188196
- "--exclude=features/full_tests/anr.feature"
197+
- "--repeater-api-key="
198+
- "--hub-repeater-api-key="
189199
test-collector#v1.10.2:
190200
files: "reports/TEST-*.xml"
191201
format: "junit"
@@ -220,6 +230,8 @@ steps:
220230
- "--aws-public-ip"
221231
- "--farm=bb"
222232
- "--device=ANDROID_7"
233+
- "--repeater-api-key="
234+
- "--hub-repeater-api-key="
223235
test-collector#v1.10.2:
224236
files: "reports/TEST-*.xml"
225237
format: "junit"
@@ -253,6 +265,8 @@ steps:
253265
- "--aws-public-ip"
254266
- "--farm=bb"
255267
- "--device=ANDROID_7"
268+
- "--repeater-api-key="
269+
- "--hub-repeater-api-key="
256270
test-collector#v1.10.2:
257271
files: "reports/TEST-*.xml"
258272
format: "junit"
@@ -286,6 +300,8 @@ steps:
286300
- "--device=ANDROID_8"
287301
- "--exclude=features/full_tests/[^a-k].*.feature"
288302
- "--exclude=features/full_tests/anr.feature"
303+
- "--repeater-api-key="
304+
- "--hub-repeater-api-key="
289305
test-collector#v1.10.2:
290306
files: "reports/TEST-*.xml"
291307
format: "junit"
@@ -319,6 +335,8 @@ steps:
319335
- "--aws-public-ip"
320336
- "--farm=bb"
321337
- "--device=ANDROID_8"
338+
- "--repeater-api-key="
339+
- "--hub-repeater-api-key="
322340
test-collector#v1.10.2:
323341
files: "reports/TEST-*.xml"
324342
format: "junit"
@@ -349,6 +367,8 @@ steps:
349367
- "--appium-version=1.22.0"
350368
- "--farm=bs"
351369
- "--device=ANDROID_8"
370+
- "--repeater-api-key="
371+
- "--hub-repeater-api-key="
352372
test-collector#v1.10.2:
353373
files: "reports/TEST-*.xml"
354374
format: "junit"

.buildkite/pipeline.yml

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,11 +40,9 @@ steps:
4040
- "build/bs-fixture-r21-url.txt"
4141
- "build/fixture-r21/*"
4242
commands:
43-
- bundle install
44-
- make fixture-r21
45-
- bundle exec upload-app --farm=bb --app=./build/fixture-r21.apk --app-id-file=build/fixture-r21-url.txt
46-
- bundle exec upload-app --farm=bs --app=./build/fixture-r21.apk --app-id-file=build/bs-fixture-r21-url.txt
43+
- ruby scripts/build-test-fixture.rb
4744
env:
45+
ANDROID_NDK_ROOT: "/Users/administrator/Library/Android/sdk/ndk/26.1.10909125"
4846
JAVA_VERSION: 17
4947

5048
- label: ':android: Coding standards checks'
@@ -130,6 +128,8 @@ steps:
130128
- "--aws-public-ip"
131129
- "--farm=bb"
132130
- "--device=ANDROID_7"
131+
- "--repeater-api-key="
132+
- "--hub-repeater-api-key="
133133
test-collector#v1.10.2:
134134
files: "reports/TEST-*.xml"
135135
format: "junit"
@@ -163,6 +163,8 @@ steps:
163163
- "--aws-public-ip"
164164
- "--farm=bb"
165165
- "--device=ANDROID_7"
166+
- "--repeater-api-key="
167+
- "--hub-repeater-api-key="
166168
test-collector#v1.10.2:
167169
files: "reports/TEST-*.xml"
168170
format: "junit"
@@ -195,6 +197,8 @@ steps:
195197
- "--aws-public-ip"
196198
- "--farm=bb"
197199
- "--device=ANDROID_8"
200+
- "--repeater-api-key="
201+
- "--hub-repeater-api-key="
198202
test-collector#v1.10.2:
199203
files: "reports/TEST-*.xml"
200204
format: "junit"
@@ -224,6 +228,8 @@ steps:
224228
- "--appium-version=1.22.0"
225229
- "--farm=bs"
226230
- "--device=ANDROID_8"
231+
- "--repeater-api-key="
232+
- "--hub-repeater-api-key="
227233
test-collector#v1.10.2:
228234
files: "reports/TEST-*.xml"
229235
format: "junit"
Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
-keep class com.bugsnag.android.mazerunner.** {*;}
1+
-keep class com.bugsnag.android.mazerunner.scenarios.** {*;}
2+
-keep class com.bugsnag.android.mazerunner.SomeException {*;}
23
-keep class com.bugsnag.android.DeliveryDelegate {*;}
34
-keepattributes LineNumberTable,SourceFile
4-
-renamesourcefileattribute SourceFile
5+
-renamesourcefileattribute SourceFile

scripts/build-test-fixture.rb

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
def upload_files(api_key, dest)
2+
Dir.chdir('features/fixtures/mazerunner') do
3+
upload = "bugsnag-cli upload"
4+
options = "--api-key=#{api_key} --overwrite --version-code=1"
5+
puts "Uploading symbol files to #{dest}"
6+
puts `#{upload} android-ndk #{options}`
7+
puts "Uploading mapping file to #{dest}"
8+
puts `#{upload} android-proguard #{options} --application-id=com.bugsnag.android.mazerunner`
9+
end
10+
end
11+
12+
puts 'Building test fixture'
13+
puts `bundle install`
14+
puts `make fixture-r21`
15+
16+
upload_files(ENV['MAZE_REPEATER_API_KEY'], 'bugsnag.com') if ENV['MAZE_REPEATER_API_KEY']
17+
upload_files(ENV['MAZE_HUB_REPEATER_API_KEY'], 'Insight Hub') if ENV['MAZE_HUB_REPEATER_API_KEY']
18+
19+
puts 'Uploading to BrowserStack and BitBar'
20+
puts `bundle exec upload-app --farm=bb --app=./build/fixture-r21.apk --app-id-file=build/fixture-r21-url.txt`
21+
puts `bundle exec upload-app --farm=bs --app=./build/fixture-r21.apk --app-id-file=build/bs-fixture-r21-url.txt`

0 commit comments

Comments
 (0)