Android Studio test between two emulators : <p>Okay so, I have two emulators running. I want to write a test where one device calls the other device using VOIP. My goal is to automate VOIP testing.</p>

<p>A <code>successCount</code> variable is defined inside the test class to validate whether the test was successful or not.</p>

<p>Steps I need to take in my test class:</p>

<ol>
<li>Login into the SIP server with device A.</li>
<li>Login into the SIP server with device B.</li>
<li>Device A calls device B (increase success count by 1).</li>
<li>Device B answers the call (increase success count by 1).</li>
<li>Device B hangsup after 5 seconds (increase success count by 1).</li>
<li>Assert that success count is equal to 3.</li>
</ol>

<p>Now the issue I have is the sequence of the steps on the devices. I need to tell device A to call device B after that device B has been logged into the SIP server for example. Currently I'm unable to accomplish this in an instrumented or unit test.</p>

<p>Does anyone know a solution to sequentially execute (unit/instrumented) test code in two device emulators in Android Studio? Is this even possible?</p>
