---
title: Step 3. Test the app
description: Provides instructions on how to test the iOS DaVinci sample app, including logging in, registering a new user, viewing user information, and logging out.
component: orchsdks
page_id: orchsdks:davinci:try-it-out/ios/03_running-sample-pingone
canonical_url: https://developer.pingidentity.com/orchsdks/davinci/try-it-out/ios/03_running-sample-pingone.html
revdate: Fri, 17 Oct 2025 14:50:55 +0100
keywords: ["DaVinci", "iOS", "Test", "Run", "Sample App", "Tutorial"]
section_ids:
  log_in_as_a_demo_user: Log in as a demo user
---

# Step 3. Test the app

[icon: circle-check, set=far]PingOne [icon: apple, set=fab]iOS

* [Prepare](00_before-you-begin.html)

* [Download](01_downloading-forgerocksdk.html)

* [Configure](02_configuring-sample-for-davinci.html)

* **Run**

In the following procedure, you run the sample app that you configured in the previous step. The app performs a centralized login on your PingOne instance.

## Log in as a demo user

1. In Xcode, select **Product** [icon: angle-right, set=fa] **Run**.

   Xcode launches the sample app in the iPhone simulator.

   ![ios kotlin davinci main menu](../../_images/ios-kotlin-davinci-main-menu.png)Figure 1. The iOS DaVinci sample main menu

2. In the sample app on the iPhone simulator, tap Launch Davinci.

   The sample app launches the DaVinci flow configured in the OAuth 2.0 profile.

   ![ios kotlin davinci login](../../_images/ios-kotlin-davinci-login.png)Figure 2. The DaVinci sample app first screen with fields and buttons.

3. Optionally, to register a new identity in PingOne:

   1. Tap the **No Account? Register now!** link.

      |   |                                            |
      | - | ------------------------------------------ |
      |   | This link is an example of a `FlowButton`. |

      The app displays the registration screen:

      ![The DaVinci sample app registration screen](../../_images/ios-kotlin-davinci-register.png)Figure 3. The DaVinci sample app registration screen.

   2. Enter the details of the new identity, and then click **Save**.

      The app creates the new identity in PingOne and returns to the sign on screen.

4. Sign on as a demo user:

   * Name: `demo`

   * Password: `Ch4ng3it!`

   If authentication is successful, the application displays the tokens issued by PingOne.

   ![ios kotlin davinci access token](../../_images/ios-kotlin-davinci-access-token.png)Figure 4. The token issues by the DaVinci flow

5. Tap [icon: chevron-left, set=fas, size=xs]Davinci to go back to the main menu, and then tap User Info.

   The app retrieves the user's info from the `/userinfo` endpoint and displays it on screen:

   ![ios kotlin davinci userinfo](../../_images/ios-kotlin-davinci-userinfo.png)Figure 5. User info retrieved from PingOne

6. Tap [icon: chevron-left, set=fas, size=xs]Davinci to go back to the main menu, and then tap Logout.

   The sample app displays a logout button.

   ![ios kotlin davinci logout](../../_images/ios-kotlin-davinci-logout.png)Figure 6. Logout button in the iOS sample app

7. Tap Proceed to logout

   The app revokes the existing tokens and ends the session in PingOne.

   |   |                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
   | - | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
   |   | To verify the user is signed out:1) In the PingOne administration console, navigate to **Directory > Users**.

   2) Select the user you signed in as.

   3) From the Services dropdown, select Authentication:

      ![pingone sessions en](../../../_images/pingone-sessions-en.png)Figure 7. Checking a user's sessions in PingOne.

      The Sessions section displays any existing sessions the user has, and whether they originate from a mobile device. |
