Skip to content

Commit b117069

Browse files
committed
Run all API levels
1 parent a195d9c commit b117069

File tree

2 files changed

+10
-8
lines changed

2 files changed

+10
-8
lines changed

.github/workflows/builtAndTest.yml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
build-and-test-client:
1313
strategy:
1414
matrix:
15-
api-level: [33]
15+
api-level: [30, 33, 35]
1616

1717
runs-on: ubuntu-latest
1818

@@ -65,10 +65,12 @@ jobs:
6565
with:
6666
api-level: ${{ matrix.api-level }}
6767
arch: x86_64
68-
script: |
69-
adb logcat -c
70-
adb logcat &
71-
gradle -is connectedCheck
68+
script: ./gradlew -is connectedCheck
69+
# Uncomment to enable logs
70+
# script: |
71+
# adb logcat -c
72+
# adb logcat &
73+
# gradle -is connectedCheck
7274

7375
build-server:
7476
runs-on: ubuntu-latest

app/src/androidTest/java/com/pcapplusplus/toyvpn/ToyVpnServiceManagerTest.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -137,15 +137,15 @@ class ToyVpnServiceManagerTest {
137137
Log.e("TestReceiveVpnStartedAndStoppedEvent", "Before sending first broadcast")
138138
context.sendBroadcast(intent)
139139
Log.e("TestReceiveVpnStartedAndStoppedEvent", "After sending first broadcast")
140-
waitFor(timeoutMillis = 20000L) { serviceManager.vpnServiceState.value == VpnConnectionState.CONNECTED }
140+
waitFor { serviceManager.vpnServiceState.value == VpnConnectionState.CONNECTED }
141141
Log.e("TestReceiveVpnStartedAndStoppedEvent", "Passed first waitFor")
142-
waitFor(timeoutMillis = 20000L) { serviceManager.clientAddress.value == "10.0.0.1" }
142+
waitFor { serviceManager.clientAddress.value == "10.0.0.1" }
143143
Log.e("TestReceiveVpnStartedAndStoppedEvent", "Passed second waitFor")
144144

145145
Log.e("TestReceiveVpnStartedAndStoppedEvent", "Before sending second broadcast")
146146
context.sendBroadcast(Intent(BroadcastActions.VPN_SERVICE_STOPPED))
147147
Log.e("TestReceiveVpnStartedAndStoppedEvent", "After sending second broadcast")
148-
waitFor(timeoutMillis = 20000L) { serviceManager.vpnServiceState.value == VpnConnectionState.DISCONNECTED }
148+
waitFor { serviceManager.vpnServiceState.value == VpnConnectionState.DISCONNECTED }
149149
Log.e("TestReceiveVpnStartedAndStoppedEvent", "Passed third waitFor")
150150
}
151151

0 commit comments

Comments
 (0)