Replace spy with mock in tests Spying ConnectionImpl fails with Java 8 with some dubious InvocationTargetException. Instead of spying the existing connection object, create a mock and make sure that it returns another mocked RemoteObject for the DropDown widget that is created internally. Change-Id: I26fe1030451ce05ab3ab35525cbaebc6a9e2b3b8