Extend raw Subject instead of supplying type parameters.
The type parameters are being removed from Subject. This CL will temporarily produce rawtypes warnings, which will go away when I remove the type parameters (as soon as this batch of CLs is submitted -- see https://github.com/google/truth/releases/tag/release_0_45). Similarly, this CL changes custom subjects to 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. Again, 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 change requires Truth 0.45, which you've already updated to. Change-Id: I75f3d1510b4c0cb06fd272b48be65e0cfd61973e
This commit is contained in:
committed by
David Pursehouse
parent
9eee01a737
commit
5f040fb432
@@ -95,8 +95,7 @@ public abstract class AbstractNotificationTest extends AbstractDaemonTest {
|
||||
gApi.accounts().self().setPreferences(prefs);
|
||||
}
|
||||
|
||||
protected static class FakeEmailSenderSubject
|
||||
extends Subject<FakeEmailSenderSubject, FakeEmailSender> {
|
||||
protected static class FakeEmailSenderSubject extends Subject {
|
||||
private final FakeEmailSender fakeEmailSender;
|
||||
private Message message;
|
||||
private StagedUsers users;
|
||||
|
||||
Reference in New Issue
Block a user