@Override
        protected void afterActivityLaunched() {
            // Technically we do not need to do this - WebViewActivity has javascript turned on.
            // Other WebViews in your app may have javascript turned off, however since the only way
            // to automate WebViews is through javascript, it must be enabled.
            onWebView().forceJavascriptEnabled();
        }
A JUnit {@link Rule @Rule} to launch your activity under test. This is a replacement
for {@link android.test.ActivityInstrumentationTestCase2}.
<p>
Rules are interceptors which are executed for each test method and will run before
any of your setup code in the {@link Before @Before} method.
<p>
{@link ActivityTestRule} will create and launch of the activity for you and also expose
the activity under test. To get a reference to the activity you can use
the {@link ActivityTestRule#getActivity()} method.
ui/espresso/WebBasicSample/app/src/androidTest/java/com/example/android/testing/espresso/web/BasicSample/WebViewActivityTest.java