Getting "Repositroy test has failed" error while cloning repository from Gitlab in Android Studio?
You need to download and install git from http://git-scm.com/downloads
Then you need to track the git.exe on AndroidStudio:
Go to Settings > Project Settings > Version Control > VCSs > Git > Path to Git executable
Select (or type) executable path, eg:
D:\Program Files (x86)\Git\cmd\git.exe
If you installed GitHub Desktop for Windows
In case you have GitHub Desktop for Windows, git.exe
will be found at C:\Users\YOUR_USER_NAME\AppData\Local\GitHub\PortableGit_c7e0cbde92ba565zz218z5214zzz0e854zzza28\cmd
.
If you Installed git from http://git-scm.com/downloads and also sett the correct path and still get an error maybe you sit behind a Proxy, in this case you have to add the Proxy to the git. This is Possible in the gitconfig. Wich should be avaiable in :\Program Files (x86)\Git\etc if you used the standard path for installation.
I am on Ubuntu 16.04 (this applies to other versions as well) and all I needed to do was to install git from apt-get:
sudo apt-get install git
This means Android Studio was trying to execute git command but it could not be recognized so if you have git installed then try to execute git from terminal and if not recognized then you should configure paths to git executable. That was it!!!