Skip to content

Commit 638269b

Browse files
committed
Add Lint + Test steps
1 parent bc2957c commit 638269b

File tree

4 files changed

+58
-0
lines changed

4 files changed

+58
-0
lines changed
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
#!/bin/bash
2+
3+
set -euo pipefail
4+
5+
echo "--- :closed_lock_with_key: Installing Secrets"
6+
./gradlew applyConfiguration
7+
8+
echo "--- :gcloud: Logging into Google Cloud"
9+
gcloud auth activate-service-account --key-file .configure-files/firebase.secrets.json
10+
11+
echo "--- :hammer_and_wrench: Building Tests"
12+
./gradlew --stacktrace app:assembleDebug app:assembleDebugAndroidTest
13+
14+
echo "\n--- :firebase: Run Tests" # Line break fixes the next heading
15+
gcloud firebase test android run \
16+
--project api-project-108380595987 \
17+
--type instrumentation \
18+
--app app/build/outputs/apk/debug/app-debug.apk \
19+
--test app/build/outputs/apk/androidTest/debug/app-debug-androidTest.apk \
20+
--device model=Nexus5X,version=26,locale=en,orientation=portrait \
21+
--verbosity info

.buildkite/commands/lint.sh

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
#!/bin/bash
2+
3+
set -euo pipefail
4+
5+
echo "--- ktlint"
6+
./gradlew --stacktrace ktlint
7+
8+
echo "--- lintRelease"
9+
./gradlew --stacktrace lintRelease

.buildkite/commands/unit-test.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
#!/bin/bash
2+
3+
set -euo pipefail
4+
5+
echo "--- Unit Test"
6+
./gradlew --stacktrace aztec:testRelease
7+

.buildkite/pipeline.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,27 @@ common_params:
99
- automattic/bash-cache#2.6.0
1010

1111
steps:
12+
- label: "Lint"
13+
key: "lint"
14+
command: .buildkite/commands/lint.sh
15+
plugins: *common_plugins
16+
artifact_paths:
17+
- "aztec/build/reports/*"
18+
19+
- label: "Unit Tests"
20+
key: "test"
21+
command: .buildkite/commands/unit-test.sh
22+
plugins: *common_plugins
23+
artifact_paths:
24+
- "aztec/build/test-results/**/*.xml"
25+
26+
- label: "Connected Tests"
27+
key: "connected-test"
28+
command: .buildkite/commands/connected-tests.sh
29+
plugins: *common_plugins
30+
artifact_paths:
31+
- "aztec/build/test-results/**/*.xml"
32+
1233
- label: "Publish :aztec"
1334
key: "publish-aztec"
1435
command: .buildkite/commands/publish-aztec.sh

0 commit comments

Comments
 (0)