Step 7. Test the app
In this step, you run and test your application.
You run it in the emulator or on your Android device, perform authentication with a demo user, check the log for success messages, and then log out the user.
Log in as a demo user
-
In Android Studio, select
. -
Click Log in.
The fragment dialog appears, with fields for both name and password, as well as continue and cancel buttons:
-
Enter the credentials of the demo user:
-
Name:
demo
-
Password:
Ch4ng3it!
-
-
Click Continue.
If authentication is successful, the application returns to the main screen, and displays "User is authenticated."
-
Open the Logcat pane.
If authentication was successful, the log contains entries similar to the following:
13:41:37 D [3.4.0]: Journey finished with Success outcome. 13:41:37 D [3.4.0]: Token received.
If authentication fails:
-
Check the credentials you are using are correct.
For example, attempt to log directly into your ID Cloud or AM instance using them.
-
Check your
strings.xml
has the correct values for your environment
-
-
Click the Log out button.
If logout is successful, the application displays "User is not authenticated."
The Logcat pane contains entries similar to the following:
14:27:31 D [3.4.0]: Revoke success 14:27:31 D [3.4.0]: Revoking AccessToken & Refresh Token Success
Next Steps
-
Update your app to handle additional supported callbacks.
-
Improve the security of your application by adding SSL pinning.
-
Add the ability to update your configuration without reinstalling the app, with dynamic configuration.
-
Offer "magic links" to your users by adding support for suspending and resuming authentication.