Upstream changes (#23)

This commit is contained in:
2024-07-11 02:12:32 +03:00
committed by GitHub
parent 8a6378f509
commit 3503ecffab
906 changed files with 23577 additions and 24115 deletions
@@ -0,0 +1,46 @@
package com.meloda.app.fast.tests
import androidx.compose.ui.test.assertHasClickAction
import androidx.compose.ui.test.junit4.createComposeRule
import androidx.compose.ui.test.onNodeWithTag
import androidx.compose.ui.test.performClick
import org.junit.Rule
import org.junit.Test
class LoginSignInTest {
@get:Rule
val composeTestRule = createComposeRule()
@Test
fun signInButtonIsClickable() {
composeTestRule.setContent {
// LogoScreen(onAction = {})
}
composeTestRule.onNodeWithTag(testTag = "Sign in button").assertHasClickAction()
}
@Test
fun signInButtonTriggersSignInAction() {
var signInClicked = true
composeTestRule.setContent {
// com.meloda.fast.auth.login.presentation.LogoScreen(
// onAction = { action ->
// when (action) {
// UiAction.NextClicked -> {
// signInClicked = true
// }
//
// else -> Unit
// }
// }
// )
}
composeTestRule.onNodeWithTag("Sign in button").performClick()
assert(signInClicked)
}
}