Skip to content

Commit

Permalink
run test in azure
Browse files Browse the repository at this point in the history
  • Loading branch information
saikrishna321 committed May 6, 2024
1 parent c716730 commit a5efa93
Showing 1 changed file with 2 additions and 57 deletions.
59 changes: 2 additions & 57 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
@@ -1,62 +1,7 @@
trigger:
- dashboard-module
- dashboard-ui

jobs:
- job: UnitTest
pool:
vmImage: 'macOS-latest'
steps:
- task: [email protected]
inputs:
versionSpec: '20.x'
- template: templates/pipeline.yml
- script: |
npm test
displayName: 'npm test'
- script: |
npm run prettier-check
displayName: 'Prettier check'
- job: ANDROID
pool:
vmImage: 'macOS-latest'

steps:
- task: [email protected]
inputs:
versionSpec: '20.x'
- template: templates/pipeline.yml
- bash: |
echo "y" | $ANDROID_HOME/tools/bin/sdkmanager --install 'system-images;android-27;google_apis;x86'
displayName: "install Android image"
- script: |
$ANDROID_HOME/emulator/emulator -list-avds
echo '---'
echo "no" | $ANDROID_HOME/tools/bin/avdmanager create avd -n test_android_emulator -k 'system-images;android-27;google_apis;x86' --force
echo '---'
echo '---'
echo "no" | $ANDROID_HOME/tools/bin/avdmanager create avd -n test_android_emulator1 -k 'system-images;android-27;google_apis;x86' --force
echo '---'
$ANDROID_HOME/emulator/emulator -list-avds
displayName: "create AVD"
- script: |
$ANDROID_HOME/platform-tools/adb devices
echo '---'
nohup $ANDROID_HOME/emulator/emulator -avd test_android_emulator -verbose -no-boot-anim -no-audio -no-window -gpu swiftshader_indirect > /dev/null 2>&1 & $ANDROID_HOME/platform-tools/adb wait-for-any-device shell 'while [[ -z $(getprop sys.boot_completed | tr -d '\r') ]]; do sleep 1; done; input keyevent 82'
echo '---'
echo '---'
nohup $ANDROID_HOME/emulator/emulator -avd test_android_emulator1 -verbose -no-boot-anim -no-audio -no-window -gpu swiftshader_indirect > /dev/null 2>&1 & $ANDROID_HOME/platform-tools/adb wait-for-any-device shell 'while [[ -z $(getprop sys.boot_completed | tr -d '\r') ]]; do sleep 1; done; input keyevent 82'
echo '---'
$ANDROID_HOME/platform-tools/adb devices
$ANDROID_HOME/platform-tools/adb kill-server
echo '----devices after kill server----'
$ANDROID_HOME/platform-tools/adb devices
displayName: "start Android emulator"
- script: |
npm run build --if-present
npm run integration-android
displayName: "Android Integration Test"
- job: E2EPluginTest
pool:
vmImage: 'macOS-latest'
Expand Down Expand Up @@ -189,4 +134,4 @@ jobs:
export CLOUD_KEY=$LT_PASSWORD
export LT_CLOUD_APP=$LT_CLOUD_APP
npm run test-parallel-lt
displayName: 'E2E Test'
displayName: 'E2E Test'

0 comments on commit a5efa93

Please sign in to comment.