Closed Corvus400 closed 1 year ago
The PR conflict in #1061 could not be resolved, so it was reworked. 🙇
211 tests 211 :heavy_check_mark: 7m 37s :stopwatch: 11 suites 0 :zzz: 11 files 0 :x:
Results for commit 6faaa0a6.
:recycle: This comment has been updated with latest results.
I think you can download the test report. I'm not sure why there are two root but it may be because of the dialog, right? We can select it onNodes(isRoot).onFirst or something. Could you check it out?
composeTestRule
.onNode(isRoot())
.captureRoboImage()
java.lang.AssertionError: fail to captureRoboImage
Reason: Expected exactly '1' node but found '2' nodes that satisfy: (isRoot)
Nodes found:
1) Node #1 at (l=0.0, t=84.0, r=480.0, b=799.0)px
Has 1 child
2) Node #30 at (l=0.0, t=0.0, r=480.0, b=461.0)px
Has 1 child
at androidx.compose.ui.test.SemanticsNodeInteraction.fetchOneOrDie(SemanticsNodeInteraction.kt:145)
at androidx.compose.ui.test.SemanticsNodeInteraction.fetchSemanticsNode(SemanticsNodeInteraction.kt:79)
at com.github.takahirom.roborazzi.RoborazziKt.captureRoboImage(Roborazzi.kt:220)
at com.github.takahirom.roborazzi.RoborazziKt.captureRoboImage(Roborazzi.kt:210)
at com.github.takahirom.roborazzi.RoborazziKt.captureRoboImage$default(Roborazzi.kt:205)
at io.github.droidkaigi.confsched2023.testing.robot.AchievementsScreenRobot.checkScreenCapture(AchievementsScreenRobot.kt:56)
at io.github.droidkaigi.confsched2023.achievements.AchievementsScreenTest$checkLaunchShot$1.invoke(AchievementsScreenTest.kt:38)
at io.github.droidkaigi.confsched2023.achievements.AchievementsScreenTest$checkLaunchShot$1.invoke(AchievementsScreenTest.kt:36)
at io.github.droidkaigi.confsched2023.testing.robot.AchievementsScreenRobot$invoke$1.invokeSuspend(AchievementsScreenRobot.kt:27)
at io.github.droidkaigi.confsched2023.testing.robot.AchievementsScreenRobot$invoke$1.invoke(AchievementsScreenRobot.kt)
at io.github.droidkaigi.confsched2023.testing.robot.AchievementsScreenRobot$invoke$1.invoke(AchievementsScreenRobot.kt)
at io.github.droidkaigi.confsched2023.testing.coroutines.RunTestWithLoggingKt$runTestWithLogging$1$1$1.invokeSuspend(RunTestWithLogging.kt:18)
at io.github.droidkaigi.confsched2023.testing.coroutines.RunTestWithLoggingKt$runTestWithLogging$1$1$1.invoke(RunTestWithLogging.kt)
at io.github.droidkaigi.confsched2023.testing.coroutines.RunTestWithLoggingKt$runTestWithLogging$1$1$1.invoke(RunTestWithLogging.kt)
at kotlinx.coroutines.intrinsics.UndispatchedKt.startUndispatchedOrReturn(Undispatched.kt:78)
at kotlinx.coroutines.CoroutineScopeKt.coroutineScope(CoroutineScope.kt:264)
at io.github.droidkaigi.confsched2023.testing.coroutines.RunTestWithLoggingKt$runTestWithLogging$1.invokeSuspend(RunTestWithLogging.kt:17)
at io.github.droidkaigi.confsched2023.testing.coroutines.RunTestWithLoggingKt$runTestWithLogging$1.invoke(RunTestWithLogging.kt)
at io.github.droidkaigi.confsched2023.testing.coroutines.RunTestWithLoggingKt$runTestWithLogging$1.invoke(RunTestWithLogging.kt)
at kotlinx.coroutines.test.TestBuildersKt__TestBuildersKt$runTest$2$1$1.invokeSuspend(TestBuilders.kt:314)
at _COROUTINE._BOUNDARY._(CoroutineDebugging.kt:46)
at io.github.droidkaigi.confsched2023.testing.coroutines.RunTestWithLoggingKt$runTestWithLogging$1.invokeSuspend(RunTestWithLogging.kt:17)
at kotlinx.coroutines.test.TestBuildersKt__TestBuildersKt$runTest$2$1$1.invokeSuspend(TestBuilders.kt:314)
Caused by: java.lang.AssertionError: fail to captureRoboImage
Reason: Expected exactly '1' node but found '2' nodes that satisfy: (isRoot)
Nodes found:
1) Node #1 at (l=0.0, t=84.0, r=480.0, b=799.0)px
Has 1 child
2) Node #30 at (l=0.0, t=0.0, r=480.0, b=461.0)px
Snapshot diff report | File name | Image |
---|---|---|
KaigiAppTest.checkNa vigateToAchievements Shot_compare.png |
I've checked the diff and It seems that we don't have any image change in diff!
@takahirom @momomomo111 Hmmm...in the local KaigiAppTest screenshot test, as shown in the attached video, KaigiAppTest.checkNavigateToAchievementsShot.png successfully selects the AchievementsScreen tab and a screenshot is taken. I do not know how to further address this issue on my end.🤯 Can you please help me?😭
@Corvus400 I think the implementation is great! I just wanted @momomomo111 to review the specification!
ちょっと誤解ありそうなので日本語で書きます🙇 diff無いというのはいい意味です!スクショテストについての問題は今は解決されてると思います!
@Corvus400 @takahirom Thanks! I think there's no problem with the specifications. I believe it's a cool implementation!
Unfortunately, there is a PR that will cause conflict. It is a core implementation for the achievements and it is larger than this pr. Maybe we are going to merge the pr first. 🙇 https://github.com/DroidKaigi/conference-app-2023/pull/1043
I think you can download the test report. I'm not sure why there are two root but it may be because of the dialog, right? We can select it onNodes(isRoot).onFirst or something. Could you check it out?
composeTestRule .onNode(isRoot()) .captureRoboImage()
java.lang.AssertionError: fail to captureRoboImage Reason: Expected exactly '1' node but found '2' nodes that satisfy: (isRoot) Nodes found: 1) Node #1 at (l=0.0, t=84.0, r=480.0, b=799.0)px Has 1 child 2) Node #30 at (l=0.0, t=0.0, r=480.0, b=461.0)px Has 1 child at androidx.compose.ui.test.SemanticsNodeInteraction.fetchOneOrDie(SemanticsNodeInteraction.kt:145) at androidx.compose.ui.test.SemanticsNodeInteraction.fetchSemanticsNode(SemanticsNodeInteraction.kt:79) at com.github.takahirom.roborazzi.RoborazziKt.captureRoboImage(Roborazzi.kt:220) at com.github.takahirom.roborazzi.RoborazziKt.captureRoboImage(Roborazzi.kt:210) at com.github.takahirom.roborazzi.RoborazziKt.captureRoboImage$default(Roborazzi.kt:205) at io.github.droidkaigi.confsched2023.testing.robot.AchievementsScreenRobot.checkScreenCapture(AchievementsScreenRobot.kt:56) at io.github.droidkaigi.confsched2023.achievements.AchievementsScreenTest$checkLaunchShot$1.invoke(AchievementsScreenTest.kt:38) at io.github.droidkaigi.confsched2023.achievements.AchievementsScreenTest$checkLaunchShot$1.invoke(AchievementsScreenTest.kt:36) at io.github.droidkaigi.confsched2023.testing.robot.AchievementsScreenRobot$invoke$1.invokeSuspend(AchievementsScreenRobot.kt:27) at io.github.droidkaigi.confsched2023.testing.robot.AchievementsScreenRobot$invoke$1.invoke(AchievementsScreenRobot.kt) at io.github.droidkaigi.confsched2023.testing.robot.AchievementsScreenRobot$invoke$1.invoke(AchievementsScreenRobot.kt) at io.github.droidkaigi.confsched2023.testing.coroutines.RunTestWithLoggingKt$runTestWithLogging$1$1$1.invokeSuspend(RunTestWithLogging.kt:18) at io.github.droidkaigi.confsched2023.testing.coroutines.RunTestWithLoggingKt$runTestWithLogging$1$1$1.invoke(RunTestWithLogging.kt) at io.github.droidkaigi.confsched2023.testing.coroutines.RunTestWithLoggingKt$runTestWithLogging$1$1$1.invoke(RunTestWithLogging.kt) at kotlinx.coroutines.intrinsics.UndispatchedKt.startUndispatchedOrReturn(Undispatched.kt:78) at kotlinx.coroutines.CoroutineScopeKt.coroutineScope(CoroutineScope.kt:264) at io.github.droidkaigi.confsched2023.testing.coroutines.RunTestWithLoggingKt$runTestWithLogging$1.invokeSuspend(RunTestWithLogging.kt:17) at io.github.droidkaigi.confsched2023.testing.coroutines.RunTestWithLoggingKt$runTestWithLogging$1.invoke(RunTestWithLogging.kt) at io.github.droidkaigi.confsched2023.testing.coroutines.RunTestWithLoggingKt$runTestWithLogging$1.invoke(RunTestWithLogging.kt) at kotlinx.coroutines.test.TestBuildersKt__TestBuildersKt$runTest$2$1$1.invokeSuspend(TestBuilders.kt:314) at _COROUTINE._BOUNDARY._(CoroutineDebugging.kt:46) at io.github.droidkaigi.confsched2023.testing.coroutines.RunTestWithLoggingKt$runTestWithLogging$1.invokeSuspend(RunTestWithLogging.kt:17) at kotlinx.coroutines.test.TestBuildersKt__TestBuildersKt$runTest$2$1$1.invokeSuspend(TestBuilders.kt:314) Caused by: java.lang.AssertionError: fail to captureRoboImage Reason: Expected exactly '1' node but found '2' nodes that satisfy: (isRoot) Nodes found: 1) Node #1 at (l=0.0, t=84.0, r=480.0, b=799.0)px Has 1 child 2) Node #30 at (l=0.0, t=0.0, r=480.0, b=461.0)px
Hello,
I am also having same problem. did you find any solution for this ?
Issue
Overview (Required)
Movie (Optional)