This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Steps for installing the Android Emulator from EC2 console: | |
| ----------------------------------------------------------- | |
| sudo apt install default-jdk | |
| wget https://dl.google.com/android/repository/sdk-tools-linux-4333796.zip | |
| unzip sdk-tools-linux-4333796.zip -d android-sdk | |
| sudo mv android-sdk /opt/ | |
| export ANDROID_SDK_ROOT=/opt/android-sdk | |
| echo "export ANDROID_SDK_ROOT=/opt/android-sdk" >> ~/.bashrc | |
| echo "export PATH=$PATH:$ANDROID_SDK_ROOT/tools" >> ~/.bashrc | |
| re-login |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @RunWith(AndroidJUnit4.class) | |
| public class MyActivityTest { | |
| @Rule public ActivityTestRule<MyActivity> activityTestRule = new ActivityTestRule<>(MyActivity.class, false, false); | |
| private MyApp myApp; | |
| @Before public void setup() { | |
| myApp = (MyApp) InstrumentationRegistry.getTargetContext().getApplicationContext(); | |
| } |