-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
refactor+test: Auto advance #19949
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
refactor+test: Auto advance #19949
Conversation
removed in a500fe1 when Arthur tried to join the old and new study screen enums Adding it back it's necessary because I need it to be inside the `autoadvance` package so it can implement a sealed interface since the old study screen will be eventually gone, duplicating the class again seemed like the fastest approach.
a5614da to
0821d4c
Compare
AnkiDroid/src/main/java/com/ichi2/anki/ui/windows/reviewer/autoadvance/AutoAdvance.kt
Outdated
Show resolved
Hide resolved
AnkiDroid/src/main/java/com/ichi2/anki/ui/windows/reviewer/autoadvance/AutoAdvance.kt
Show resolved
Hide resolved
AnkiDroid/src/main/java/com/ichi2/anki/ui/windows/reviewer/autoadvance/AutoAdvance.kt
Show resolved
Hide resolved
david-allison
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Whoops: this is a request for a few comment in the review/commits
that makes easier to test the class
0821d4c to
0f99f86
Compare
david-allison
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cheers, nothing blocking
| @@ -1,5 +1,5 @@ | |||
| /* | |||
| * Copyright (c) 2025 Hari Srinivasan <harisrini21@gmail.com> | |||
| * Copyright (c) 2024 Brayan Oliveira <brayandso.dev@gmail.com> | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Your call on 24/25, I believe you also moved to: <69634269+brayandso@users.noreply.github.com> in newer commits
| import kotlinx.coroutines.CompletableDeferred | ||
| import kotlinx.coroutines.test.StandardTestDispatcher | ||
| import kotlinx.coroutines.test.TestScope | ||
| import kotlinx.coroutines.test.advanceTimeBy |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
advanceTimeBy has an override which accepts a Duration
Purpose / Description
Approach
In the commits
How Has This Been Tested?
Emulator 31
Screen_recording_20251227_162711.mp4
Checklist
Please, go through these checks before submitting the PR.