commit | a7c45de6145ac823f78d609991ec3a53cce05370 | [log] [tgz] |
---|---|---|
author | Ian Lake <ilake@google.com> | Fri May 24 11:01:13 2019 -0700 |
committer | android-build-merger <android-build-merger@google.com> | Fri May 24 11:01:13 2019 -0700 |
tree | c2a226c4819926a658b4d3904cbbe9af3a4d0f99 | |
parent | 97f1e9099a5439aa9aef809b8efa357c81fea3cd [diff] | |
parent | 89bd72efba9b6b52c0961a35c456648afdfa3ad3 [diff] |
Merge "SuppressWarnings for GenericLifecycleObserver" into androidx-master-dev am: 89bd72efba Change-Id: If851236abde443b1b151cfa6247f0b399c43a9d9
diff --git a/lifecycle/common/src/main/java/androidx/lifecycle/Lifecycling.java b/lifecycle/common/src/main/java/androidx/lifecycle/Lifecycling.java index 9450466..2abb6ec 100644 --- a/lifecycle/common/src/main/java/androidx/lifecycle/Lifecycling.java +++ b/lifecycle/common/src/main/java/androidx/lifecycle/Lifecycling.java
@@ -49,6 +49,7 @@ /** * @deprecated Left for compatibility with lifecycle-runtime:2.0 */ + @SuppressWarnings("deprecation") @Deprecated @NonNull static GenericLifecycleObserver getCallback(final Object object) {
diff --git a/lifecycle/common/src/test/java/androidx/lifecycle/LifecyclingTest.java b/lifecycle/common/src/test/java/androidx/lifecycle/LifecyclingTest.java index 7fd56fd..5854dce 100644 --- a/lifecycle/common/src/test/java/androidx/lifecycle/LifecyclingTest.java +++ b/lifecycle/common/src/test/java/androidx/lifecycle/LifecyclingTest.java
@@ -87,6 +87,7 @@ } // MUST BE HERE TILL Lifecycle 3.0.0 release for back-compatibility with other modules + @SuppressWarnings("deprecation") @Test public void testDeprecatedGenericLifecycleObserver() { GenericLifecycleObserver genericLifecycleObserver = new GenericLifecycleObserver() { @@ -100,6 +101,7 @@ } // MUST BE HERE TILL Lifecycle 3.0.0 release for back-compatibility with other modules + @SuppressWarnings("deprecation") @Test public void testDeprecatedLifecyclingCallback() { GenericLifecycleObserver genericLifecycleObserver = new GenericLifecycleObserver() {
diff --git a/lifecycle/runtime/src/test/java/androidx/lifecycle/LifecycleRegistryTest.java b/lifecycle/runtime/src/test/java/androidx/lifecycle/LifecycleRegistryTest.java index f12bfd3..414fb28 100644 --- a/lifecycle/runtime/src/test/java/androidx/lifecycle/LifecycleRegistryTest.java +++ b/lifecycle/runtime/src/test/java/androidx/lifecycle/LifecycleRegistryTest.java
@@ -81,6 +81,7 @@ assertThat(mRegistry.getObserverCount(), is(0)); } + @SuppressWarnings("deprecation") @Test public void addGenericAndObserve() { GenericLifecycleObserver generic = mock(GenericLifecycleObserver.class);