@@ -76,7 +76,7 @@ Describe 'MAUI app (<tfm>, <configuration>)' -ForEach @(
7676 $activity = (& xharness android adb -- shell dumpsys activity activities) -match " io\.sentry\.dotnet\.maui\.device\.integrationtestapp"
7777 if ($procid -and $activity -and $Callback )
7878 {
79- & $Callback
79+ & $Callback | ForEach-Object { Write-Host $_ }
8080 }
8181 } while ($procid -and $activity )
8282 }
@@ -191,7 +191,7 @@ Describe 'MAUI app (<tfm>, <configuration>)' -ForEach @(
191191 # Trigger BATTERY_CHANGED events by incrementing the battery level
192192 $battery = [int ](& xharness android adb -- shell dumpsys battery get level)
193193 $battery = ($battery % 100 ) + 1
194- & xharness android adb -- shell dumpsys battery set level $battery
194+ xharness android adb - v -- shell dumpsys battery set level $battery | ForEach-Object { Write-Host $_ }
195195 }
196196 }
197197
@@ -202,24 +202,23 @@ Describe 'MAUI app (<tfm>, <configuration>)' -ForEach @(
202202 }
203203 finally
204204 {
205- & xharness android adb -- shell dumpsys battery reset
205+ xharness android adb - v -- shell dumpsys battery reset | ForEach-Object { Write-Host $_ }
206206 }
207207 }
208208
209209 It ' Delivers network breadcrumbs in main thread (<configuration>)' {
210210 try
211211 {
212- $wifi = $false
213212 $result = Invoke-SentryServer {
214213 param ([string ]$url )
215214 RunAndroidApp - Dsn $url - TestArg " NETWORK_CAPABILITIES_CHANGED" {
216215 # Trigger NETWORK_CAPABILITIES_CHANGED events by toggling WiFi on/off
217- if ($wifi ) {
218- & xharness android adb -- shell svc wifi enable
216+ $wifi = (& xharness android adb -- shell settings get global wifi_on) -replace ' \s' , ' '
217+ if ($wifi -eq ' 1' ) {
218+ xharness android adb - v -- shell svc wifi disable | ForEach-Object { Write-Host $_ }
219219 } else {
220- & xharness android adb -- shell svc wifi disable
220+ xharness android adb - v -- shell svc wifi enable | ForEach-Object { Write-Host $_ }
221221 }
222- $wifi = -not $wifi
223222 }
224223 }
225224
@@ -230,7 +229,7 @@ Describe 'MAUI app (<tfm>, <configuration>)' -ForEach @(
230229 }
231230 finally
232231 {
233- & xharness android adb -- shell svc wifi enable
232+ xharness android adb - v -- shell svc wifi enable | ForEach-Object { Write-Host $_ }
234233 }
235234 }
236235}
0 commit comments