Yesterday I also just summarized an article on unit testing in my blog. Who knows that I encountered a problem when I wrote a unit test this afternoon and had to solve it until now.
The following problem is always prompted during unit test execution:
The connection to ADB is down, and a severe error has occured.
...
Test launch failed: cocould not connect ::
Connect to eclipse test result listener failed
Before this problem, I had a problem because of the example of a mobile phone Test Written by a student who installed the pea pod. Who knows that the pea pod occupies the ADB running Android, and the project cannot run, in this case, stop the pod process and run the project. In order to avoid similar problems, I simply unmounted the pods and did not expect to report the above errors when running the unit test. Solution:
CMD jump to the SDK tools file path
ADB kill-Server
Then ADB start-Server
It is okay to run the pod again. My personal summary: it may be that the ADB service involved by the Pod itself needs to be restarted after it is uninstalled.
Post it on your blog, hoping to help you.