Skip to content
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

Fix tests #1563

Merged
merged 1 commit into from
May 12, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -290,23 +290,23 @@ class LottieTest {
}

private suspend fun snapshotScaleTypes() = withContext(Dispatchers.Main) {
withAnimationView("LottieLogo1.json", "Scale Types", "Wrap Content") { animationView ->
withAnimationView("Lottie Logo 1.json", "Scale Types", "Wrap Content") { animationView ->
animationView.progress = 1f
animationView.updateLayoutParams {
width = ViewGroup.LayoutParams.WRAP_CONTENT
height = ViewGroup.LayoutParams.WRAP_CONTENT
}
}

withAnimationView("LottieLogo1.json", "Scale Types", "Match Parent") { animationView ->
withAnimationView("Lottie Logo 1.json", "Scale Types", "Match Parent") { animationView ->
animationView.progress = 1f
animationView.updateLayoutParams {
width = ViewGroup.LayoutParams.MATCH_PARENT
height = ViewGroup.LayoutParams.MATCH_PARENT
}
}

withAnimationView("LottieLogo1.json", "Scale Types", "300x300@2x") { animationView ->
withAnimationView("Lottie Logo 1.json", "Scale Types", "300x300@2x") { animationView ->
animationView.progress = 1f
animationView.updateLayoutParams {
width = 300.dp.toInt()
Expand All @@ -315,7 +315,7 @@ class LottieTest {
animationView.scale = 2f
}

withAnimationView("LottieLogo1.json", "Scale Types", "300x300@4x") { animationView ->
withAnimationView("Lottie Logo 1.json", "Scale Types", "300x300@4x") { animationView ->
animationView.progress = 1f
animationView.updateLayoutParams {
width = 300.dp.toInt()
Expand All @@ -324,7 +324,7 @@ class LottieTest {
animationView.scale = 4f
}

withAnimationView("LottieLogo1.json", "Scale Types", "300x300 centerCrop") { animationView ->
withAnimationView("Lottie Logo 1.json", "Scale Types", "300x300 centerCrop") { animationView ->
animationView.progress = 1f
animationView.updateLayoutParams {
width = 300.dp.toInt()
Expand All @@ -333,7 +333,7 @@ class LottieTest {
animationView.scaleType = ImageView.ScaleType.CENTER_CROP
}

withAnimationView("LottieLogo1.json", "Scale Types", "300x300 centerInside") { animationView ->
withAnimationView("Lottie Logo 1.json", "Scale Types", "300x300 centerInside") { animationView ->
animationView.progress = 1f
animationView.updateLayoutParams {
width = 300.dp.toInt()
Expand All @@ -342,7 +342,7 @@ class LottieTest {
animationView.scaleType = ImageView.ScaleType.CENTER_INSIDE
}

withAnimationView("LottieLogo1.json", "Scale Types", "300x300 fitXY") { animationView ->
withAnimationView("Lottie Logo 1.json", "Scale Types", "300x300 fitXY") { animationView ->
animationView.progress = 1f
animationView.updateLayoutParams {
width = 300.dp.toInt()
Expand All @@ -351,7 +351,7 @@ class LottieTest {
animationView.scaleType = ImageView.ScaleType.FIT_XY
}

withAnimationView("LottieLogo1.json", "Scale Types", "300x300 fitXY DisableExtraScale") {
withAnimationView("Lottie Logo 1.json", "Scale Types", "300x300 fitXY DisableExtraScale") {
animationView ->
animationView.progress = 1f
animationView.updateLayoutParams {
Expand All @@ -362,7 +362,7 @@ class LottieTest {
animationView.scaleType = ImageView.ScaleType.FIT_XY
}

withAnimationView("LottieLogo1.json", "Scale Types", "300x300 centerInside @2x") { animationView ->
withAnimationView("Lottie Logo 1.json", "Scale Types", "300x300 centerInside @2x") { animationView ->
animationView.progress = 1f
animationView.updateLayoutParams {
width = 300.dp.toInt()
Expand All @@ -372,7 +372,7 @@ class LottieTest {
animationView.scale = 2f
}

withAnimationView("LottieLogo1.json", "Scale Types", "300x300 centerCrop @2x") { animationView ->
withAnimationView("Lottie Logo 1.json", "Scale Types", "300x300 centerCrop @2x") { animationView ->
animationView.progress = 1f
animationView.updateLayoutParams {
width = 300.dp.toInt()
Expand All @@ -382,7 +382,7 @@ class LottieTest {
animationView.scale = 2f
}

withAnimationView("LottieLogo1.json", "Scale Types", "600x300 centerInside") { animationView ->
withAnimationView("Lottie Logo 1.json", "Scale Types", "600x300 centerInside") { animationView ->
animationView.progress = 1f
animationView.updateLayoutParams {
width = 600.dp.toInt()
Expand All @@ -391,7 +391,7 @@ class LottieTest {
animationView.scaleType = ImageView.ScaleType.CENTER_INSIDE
}

withAnimationView("LottieLogo1.json", "Scale Types", "600x300 fitXY") { animationView ->
withAnimationView("Lottie Logo 1.json", "Scale Types", "600x300 fitXY") { animationView ->
animationView.progress = 1f
animationView.updateLayoutParams {
width = 600.dp.toInt()
Expand All @@ -400,7 +400,7 @@ class LottieTest {
animationView.scaleType = ImageView.ScaleType.FIT_XY
}

withAnimationView("LottieLogo1.json", "Scale Types", "600x300 fitXY DisableExtraScale") { animationView ->
withAnimationView("Lottie Logo 1.json", "Scale Types", "600x300 fitXY DisableExtraScale") { animationView ->
animationView.progress = 1f
animationView.updateLayoutParams {
width = 600.dp.toInt()
Expand All @@ -410,7 +410,7 @@ class LottieTest {
animationView.scaleType = ImageView.ScaleType.FIT_XY
}

withAnimationView("LottieLogo1.json", "Scale Types", "300x600 centerInside") { animationView ->
withAnimationView("Lottie Logo 1.json", "Scale Types", "300x600 centerInside") { animationView ->
animationView.progress = 1f
animationView.updateLayoutParams {
width = 300.dp.toInt()
Expand All @@ -419,7 +419,7 @@ class LottieTest {
animationView.scaleType = ImageView.ScaleType.CENTER_INSIDE
}

withAnimationView("LottieLogo1.json", "Scale Types", "300x600 fitXY") { animationView ->
withAnimationView("Lottie Logo 1.json", "Scale Types", "300x600 fitXY") { animationView ->
animationView.progress = 1f
animationView.updateLayoutParams {
width = 300.dp.toInt()
Expand All @@ -428,7 +428,7 @@ class LottieTest {
animationView.scaleType = ImageView.ScaleType.FIT_XY
}

withAnimationView("LottieLogo1.json", "Scale Types", "300x600 fitXY DisableExtraScale") { animationView ->
withAnimationView("Lottie Logo 1.json", "Scale Types", "300x600 fitXY DisableExtraScale") { animationView ->
animationView.progress = 1f
animationView.updateLayoutParams {
width = 300.dp.toInt()
Expand Down