Skip to content

Commit

Permalink
Fix SeekBarWireframeMapper flaky test
Browse files Browse the repository at this point in the history
  • Loading branch information
ambushwork committed Oct 4, 2024
1 parent 7ebe827 commit 2825f0b
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ import com.datadog.android.sessionreplay.utils.OPAQUE_ALPHA_VALUE
import com.datadog.android.sessionreplay.utils.PARTIALLY_OPAQUE_ALPHA_VALUE
import com.datadog.tools.unit.annotations.TestTargetApi
import com.datadog.tools.unit.extensions.ApiLevelExtension
import fr.xgouchet.elmyr.annotation.FloatForgery
import fr.xgouchet.elmyr.annotation.IntForgery
import fr.xgouchet.elmyr.annotation.LongForgery
import fr.xgouchet.elmyr.annotation.StringForgery
Expand Down Expand Up @@ -60,7 +59,9 @@ internal class SeekBarWireframeMapperTest : AbstractWireframeMapperTest<SeekBar,
@IntForgery(min = 512, max = 65536)
var fakeMaxValue: Int = 0

@FloatForgery(min = 0f, max = 1f)
@IntForgery(min = 0, max = 100)
var fakeProgressInt: Int = 0

var fakeProgress: Float = 0f

@IntForgery
Expand Down Expand Up @@ -105,6 +106,7 @@ internal class SeekBarWireframeMapperTest : AbstractWireframeMapperTest<SeekBar,

@BeforeEach
fun `set up`() {
fakeProgress = fakeProgressInt / 100f
testedWireframeMapper = SeekBarWireframeMapper(
mockViewIdentifierResolver,
mockColorStringFormatter,
Expand Down

0 comments on commit 2825f0b

Please sign in to comment.