Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 25a49145 authored by Treehugger Robot's avatar Treehugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Fix default scale value" into main

parents 8ec51753 b16e4aae
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -81,12 +81,12 @@ class AodBurnInViewModelTest : SysuiTestCase() {
    }

    @Test
    fun movement_initializedToZero() =
    fun movement_initializedToDefaultValues() =
        testScope.runTest {
            val movement by collectLastValue(underTest.movement(burnInParameters))
            assertThat(movement?.translationY).isEqualTo(0)
            assertThat(movement?.translationX).isEqualTo(0)
            assertThat(movement?.scale).isEqualTo(0f)
            assertThat(movement?.scale).isEqualTo(1f)
        }

    @Test
+7 −0
Original line number Diff line number Diff line
@@ -85,6 +85,13 @@ class KeyguardRootViewModelTest : SysuiTestCase() {
        mSetFlagsRule.disableFlags(AConfigFlags.FLAG_MIGRATE_CLOCKS_TO_BLUEPRINT)
    }

    @Test
    fun defaultBurnInScaleEqualsOne() =
        testScope.runTest {
            val burnInScale by collectLastValue(underTest.scale)
            assertThat(burnInScale!!.scale).isEqualTo(1f)
        }

    @Test
    fun burnInLayerVisibility() =
        testScope.runTest {
+1 −1
Original line number Diff line number Diff line
@@ -20,6 +20,6 @@ package com.android.systemui.keyguard.shared.model
data class BurnInModel(
    val translationX: Int = 0,
    val translationY: Int = 0,
    val scale: Float = 0f,
    val scale: Float = 1f,
    val scaleClockOnly: Boolean = false,
)