summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Haibo Huang <hhb@google.com> 2019-06-01 10:05:49 -0700
committer Haibo Huang <hhb@google.com> 2019-06-03 05:27:04 +0000
commitd51a487898f3f49c850f24679a1d1c28444b2daa (patch)
treee3677fe76455938cf39cb7a30bb07fa6d2b57b9c
parentc4085073ab9339d0c7ec40315899e1af850bee5b (diff)
Fix compilation error with new kotlinc
These code failed with kotlinc v1.3.31. The new compiler is able to understand Java @NotNull. Test: build Change-Id: I7c8c7d4707805feaf4fb142fe78e40c7a53c4a7f
-rw-r--r--packages/SystemUI/tests/src/com/android/keyguard/clock/ViewPreviewerTest.kt4
1 files changed, 2 insertions, 2 deletions
diff --git a/packages/SystemUI/tests/src/com/android/keyguard/clock/ViewPreviewerTest.kt b/packages/SystemUI/tests/src/com/android/keyguard/clock/ViewPreviewerTest.kt
index d9ef7fa34883..5ece6ef1a794 100644
--- a/packages/SystemUI/tests/src/com/android/keyguard/clock/ViewPreviewerTest.kt
+++ b/packages/SystemUI/tests/src/com/android/keyguard/clock/ViewPreviewerTest.kt
@@ -47,7 +47,7 @@ class ViewPreviewerTest : SysuiTestCase() {
val width = 100
val height = 100
// WHEN a preview image is created
- val bitmap = previewer.createPreview(view, width, height)
+ val bitmap = previewer.createPreview(view, width, height)!!
// THEN the bitmap has the expected width and height
assertThat(bitmap.height).isEqualTo(height)
assertThat(bitmap.width).isEqualTo(width)
@@ -60,4 +60,4 @@ class ViewPreviewerTest : SysuiTestCase() {
canvas?.drawColor(Color.RED)
}
}
-} \ No newline at end of file
+}