Fix MailService unit tests

* These broke when we split Email/Exchange
* We now use a test authenticator and a test account type, which
  is actually far cleaner than dealing with actual accounts

Change-Id: Ib7c9f884eac484c33642a8036f47466ce641c567
diff --git a/AndroidManifest.xml b/AndroidManifest.xml
index 6ea0022..6a1cbc2 100644
--- a/AndroidManifest.xml
+++ b/AndroidManifest.xml
@@ -40,8 +40,7 @@
         android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
     <uses-permission
         android:name="android.permission.GET_ACCOUNTS" />
-    <uses-permission
-        android:name="android.permission.MANAGE_ACCOUNTS" />
+    <uses-permission android:name="android.permission.MANAGE_ACCOUNTS"/>
     <uses-permission
         android:name="android.permission.AUTHENTICATE_ACCOUNTS" />
     <uses-permission
@@ -398,6 +397,21 @@
                 android:resource="@xml/eas_authenticator"
                 />
         </service>
+        <!--Required stanza to register the EasTestAuthenticatorService with AccountManager -->
+        <service
+            android:name=".service.EasTestAuthenticatorService"
+            android:exported="true"
+            android:enabled="false"
+            >
+            <intent-filter>
+                <action
+                    android:name="android.accounts.AccountAuthenticator" />
+            </intent-filter>
+            <meta-data
+                android:name="android.accounts.AccountAuthenticator"
+                android:resource="@xml/eastest_authenticator"
+                />
+        </service>
         <!--
             EasAuthenticatorService with the alternative label.  Disabled by default,
             and OneTimeInitializer enables it if the vendor policy tells so.