1

The app I'm working on is using a service to handle accounts and authentication tokens, the gist of it is that if no account is found it should show a login screen and allow the user to log in to a new account. When building and running the app normally it works as expected, the service starts and on the first boot the user is prompted to log in to their account.

However, when running calabash-android (0.9.0) tests the service simply does not start. It is defined like this the manifest, with the name changed to provide some anonymity:

<service android:name="my.app.name.account.AppAccountAuthenticatorService">
    <intent-filter>
      <action android:name="android.accounts.AccountAuthenticator" />
    </intent-filter>
    <meta-data android:name="android.accounts.AccountAuthenticator"
               android:resource="@xml/authenticator" />
  </service>

I've also tried to manually start it in onCreate() in both the splash screen activity and main activity (not at the same time, of course) with startService(new Intent(this, AppAccountAuthenticatorService.class)); but it is still not working. I don't really know where to continue from here and I haven't fount anything online either.

0 Answers0