Status Update
Comments
je...@google.com <je...@google.com>
ap...@google.com <ap...@google.com> #2
Branch: androidx-main
commit 700259f0afe267dfe78b93db932a3cfd827a119d
Author: Sherry Hu <shuanghu@google.com>
Date: Mon May 10 14:23:09 2021
Add transition motion between fold and unfold.
Bug: 186211031
Test: manual
Change-Id: Id60f07311eca2d94ef91dc28ae45823a475160b4
M slidingpanelayout/slidingpanelayout/build.gradle
M slidingpanelayout/slidingpanelayout/src/androidTest/java/androidx/slidingpanelayout/widget/FoldTest.kt
M slidingpanelayout/slidingpanelayout/src/main/java/androidx/slidingpanelayout/widget/SlidingPaneLayout.java
ap...@google.com <ap...@google.com> #3
Branch: androidx-master-dev
commit 5959a23c5bf00899dfaa732348e93dd889426874
Author: Jelle Fresen <jellefresen@google.com>
Date: Fri Aug 07 16:42:16 2020
Add hasAwaiters, runWithManualClock and TestUiDispatcher
Added hasAwaiters to ManualFrameClock to see if anything is awaiting a
frame from it. Simply exposes BroadcastFrameClock.hasAwaiters.
Added runWithManualClock to run tests that use a ManualFrameClock.
Added TestUiDispatcher.Main to give easy and safe access to the main
coroutine dispatcher on which composition will happen.
Moved all tests in ScrollableTest to use ManualFrameClock to demo the
new features. (Well, actually the new features are the result of moving
these tests to ManualFrameClock)
Bug: 161247083
Test: ./gradlew compose:foundation:foundation:cC \
-Pandroid.testInstrumentationRunnerArguments.class=androidx.compose.foundation.test.ScrollableTest
Relnote: "Added `ManualFrameClock.hasAwaiters` to see if anything is
awaiting a frame from that clock; `runWithManualClock` as a replacement
for `runBlocking` when running tests that need a ManualFrameClock;
`TestUiDispatcher.Main` that gives easy access to the main UI dispatcher
in your tests.
For example:
```
@Test
fun myTest() = runWithManualClock { clock ->
// set some compose content
withContext(TestUiDispatcher.Main) {
clock.advanceClock(1000L)
}
if (clock.hasAwaiters) {
println("The clock has awaiters")
} else {
println("The clock has no more awaiters")
}
}
```
"
Change-Id: I0a85b019ae5f40f52f2c6b78c08958eb7b8e7485
M compose/animation/animation-core/api/current.txt
M compose/animation/animation-core/api/public_plus_experimental_current.txt
M compose/animation/animation-core/api/restricted_current.txt
M compose/animation/animation-core/src/commonMain/kotlin/androidx/compose/animation/core/ManualFrameClock.kt
M compose/foundation/foundation/src/androidAndroidTest/kotlin/androidx/compose/foundation/ScrollableTest.kt
M ui/ui-test/api/current.txt
M ui/ui-test/api/public_plus_experimental_current.txt
M ui/ui-test/api/restricted_current.txt
M ui/ui-test/build.gradle
A ui/ui-test/src/androidMain/kotlin/androidx/ui/test/CoroutineBuilders.kt
M ui/ui-test/src/commonMain/kotlin/androidx/ui/test/AnimationClocks.kt
A ui/ui-test/src/commonMain/kotlin/androidx/ui/test/TestUiDispatcher.kt
ap...@google.com <ap...@google.com> #4
Branch: androidx-master-dev
commit 3291f598f418b82cf361e9f17bb3ac641373dc53
Author: Jelle Fresen <jellefresen@google.com>
Date: Wed Aug 26 11:17:15 2020
Make TestUiDispatcher @ExperimentalTesting API
Bug: 161247083
Test: ./gradlew bOS
Relnote: "TestUiDispatcher is marked experimental"
Change-Id: Iae99dc8853f69819d969d6c1908615e69e28fb18
M compose/foundation/foundation/src/androidAndroidTest/kotlin/androidx/compose/foundation/ScrollableTest.kt
M ui/ui-test/api/current.txt
M ui/ui-test/api/public_plus_experimental_current.txt
M ui/ui-test/api/restricted_current.txt
M ui/ui-test/src/androidMain/kotlin/androidx/ui/test/CoroutineBuilders.kt
M ui/ui-test/src/commonMain/kotlin/androidx/ui/test/AnimationClocks.kt
M ui/ui-test/src/commonMain/kotlin/androidx/ui/test/TestUiDispatcher.kt
tc...@google.com <tc...@google.com> #5
ae...@google.com <ae...@google.com> #6
Hi Jelle. I was chatting with Doris today about top animation priorities before beta and deprecation+removal of AnimationClockObservable
(filed as internal
(in general, API deletions are higher priority than API additions in these last few weeks before beta). Would you be able to temporarily put aside the infinite animation work I saw you're working on this week to complete the clock transition?
pa...@google.com <pa...@google.com> #7
I think the infinite animation work is almost done so it wouldn't be worth postponing. Also we are removing other awkward APIs on our side due to this change. Is something preventing us from just deprecating the APIs? If this is only about some tests migration they can depend on test-utils which is our internal package.
ti...@google.com <ti...@google.com> #8
Re #7:
If infinite animation work is almost done, please go ahead and finish. We are in desperate need for help deprecate AnimationClockObservable
. My plate is overflowing with API finalization for Animatable
and AnimatedVisibility
right now, which won't leave enough time for the clock deprecation. :(
Could Jelle loan us a helpful hand on this high priority deprecation, if he's not swamped with critical issues himself? (It is high priority because API changes as such must be done before beta.)
je...@google.com <je...@google.com> #9
The infinite animation work is in state of completion now, and I'll start working on migration from AnimationClockObservable today.
My apologies for not responding earlier, I had to take a few days off due to circumstances. Things are better now though!
ti...@google.com <ti...@google.com> #10
Thank you so much Jelle! I really appreciate that.:)
ap...@google.com <ap...@google.com> #11
Branch: androidx-main
commit ff9e1216e79fe9480ba7ee9bcb490432221f324c
Author: Jelle Fresen <jellefresen@google.com>
Date: Thu Feb 04 19:38:09 2021
Remove MockAnimationClock
When an object requires a clock and you don't care about the clock,
create the object in composition using it's rememberXxx factory that
retrieves the ambient clock.
Bug: 161247083
Test: ./gradlew compose:foundation:foundation:cC && \
./gradlew compose:ui:ui-test:cC
Change-Id: I383420bacdc61ba27204b25bddb6648db6231d5d
M compose/foundation/foundation/src/androidAndroidTest/kotlin/androidx/compose/foundation/ScrollTest.kt
M compose/foundation/foundation/src/androidAndroidTest/kotlin/androidx/compose/foundation/ScrollableTest.kt
D compose/test-utils/src/commonMain/kotlin/androidx/compose/testutils/MockAnimationClock.kt
M compose/ui/ui-test/src/androidAndroidTest/kotlin/androidx/compose/ui/test/gesturescope/SendSwipeTest.kt
ap...@google.com <ap...@google.com> #12
Branch: androidx-main
commit 58bcedbc6dd053649cba35fd75a0347a94aab086
Author: Jelle Fresen <jellefresen@google.com>
Date: Thu Feb 04 19:01:17 2021
Remove manual clocks from material androidTest
Instead of injecting a ManualAnimationClock in the tests, create the
state objects in composition and rely on `ComposeTestRule.mainClock` to
manually advance time.
Bug: 161247083
Test: ./gradlew compose:material:material:cC
Change-Id: I8a074549e7ea939a0f30217239beee0d65635039
M compose/material/material/src/androidAndroidTest/kotlin/androidx/compose/material/BackdropScaffoldTest.kt
M compose/material/material/src/androidAndroidTest/kotlin/androidx/compose/material/BottomSheetScaffoldTest.kt
M compose/material/material/src/androidAndroidTest/kotlin/androidx/compose/material/ModalBottomSheetTest.kt
M compose/material/material/src/androidAndroidTest/kotlin/androidx/compose/material/SwipeToDismissTest.kt
M compose/material/material/src/androidAndroidTest/kotlin/androidx/compose/material/SwipeableTest.kt
Description
No description yet.