Skip to content

Commit cd37a54

Browse files
cpovirkglide-copybara-robot
authored andcommittedJun 6, 2019
Extend raw ComparableSubject instead of supplying type parameters.
The self-type parameter is being removed from ComparableSubject. In order to remove one type parameter while leaving the other in place, it's necessary either to make an atomic change (which is tricky for third-party code) or to temporarily remove *both* type parameters and then put the one back. This CL implements the latter. This CL will temporarily produce rawtypes warnings -- and temporarily eliminate type-checking of calls to the ComparableSubject methods -- which will go away when I remove the type parameters (as soon as this batch of CLs is submitted). This CL requires Truth 0.45. I should already have another CL out to you (perhaps even already submitted) to make other changes to prepare for Truth 0.45. PiperOrigin-RevId: 251895062
1 parent 6022f50 commit cd37a54

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed
 

‎third_party/disklrucache/src/test/java/com/bumptech/glide/disklrucache/DiskLruCacheTest.java

+3-1
Original file line numberDiff line numberDiff line change
@@ -930,7 +930,9 @@ private static void deleteDirectory(File file) {
930930
assertThat(!file.exists() || file.delete()).isTrue();
931931
}
932932

933-
static final class FileSubject extends ComparableSubject<FileSubject, File> {
933+
// TODO(b/134664588): Remove after go/truth-subject-lsc
934+
@SuppressWarnings({"rawtypes", "unchecked"})
935+
static final class FileSubject extends ComparableSubject {
934936
private static final Subject.Factory<FileSubject, File> FACTORY =
935937
new Subject.Factory<FileSubject, File>() {
936938
@Override

0 commit comments

Comments
 (0)
Please sign in to comment.