How to set path in Jenkins for directory with Android AVD?

When I try to build my Android workspace using Jenkins Build Now feature, it shows an error like

[android] Cannot start Android emulator: Could not start AVD 'Nexus_4', as it could 
not be found at 'C:\Windows\system32\config\systemprofile\.android\avd\Nexus_4.avd'
Recording test results
Finished: FAILURE


By default, the directory for android avd is /users/

. How can I provide this AVD path to Jenkins? It always tries to automatically find the avd in the above Windows location.

Note. I am using Windows 7 OS.


source to share

1 answer

If your command works fine on the Win command line as user "X", you should start Jenkins with the same user.

This can be achieved by following these steps:
1. Run> services.msc (Enter)
2. Select the Jenkins service. Right click and select "Properties"
3. Go to tab Log On

4. Select user "X" and provide credentials
5. Restart Jenkins

In your case, user "X" appears to be as the path to the AVD you mentioned is /users/

enter image description here



All Articles