Skip to content

Commit

Permalink
Adapt to new profile creation user flow
Browse files Browse the repository at this point in the history
  • Loading branch information
octogradiste committed May 3, 2024
1 parent 9b25aa9 commit 2dc8ccc
Showing 1 changed file with 9 additions and 16 deletions.
25 changes: 9 additions & 16 deletions app/src/androidTest/java/com/github/swent/echo/MainActivityTest.kt
Original file line number Diff line number Diff line change
Expand Up @@ -173,22 +173,15 @@ class MainActivityTest {
// Registers with google sign in
composeTestRule.onNodeWithTag("google-sign-in-button").performClick()

// TODO: Use create profile page once we have it
runBlocking {
val userId = authenticationService.getCurrentUserID()
assertNotNull(userId)
repository.setUserProfile(
UserProfile(
userId!!,
"Colin Berger",
null,
null,
emptySet(),
emptySet(),
emptySet(),
)
)
}
// The profile creation screen should be displayed
composeTestRule.onNodeWithTag("profile-creation").assertIsDisplayed()

// Insert first and last name
composeTestRule.onNodeWithTag("FirstName").performTextInput("John")
composeTestRule.onNodeWithTag("LastName").performTextInput("Doe")

// Click on the save button
composeTestRule.onNodeWithTag("Save").performClick()

// Redirected to the home screen
composeTestRule.onNodeWithTag("home_screen").assertIsDisplayed()
Expand Down

0 comments on commit 2dc8ccc

Please sign in to comment.