Fix build after DecimalType changes (#12374)

Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
This commit is contained in:
Christoph Weitkamp 2022-02-26 01:07:05 +01:00 committed by GitHub
parent da0234f69c
commit 505258c234
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -921,8 +921,10 @@ public class UpnpRendererHandlerTest extends UpnpHandlerTest {
is(cleared ? UnDefType.UNDEF : StringType.valueOf(upnpEntryQueue.get(mediaId).getGenre())));
verify(callback, atLeastOnce()).stateUpdated(eq(thing.getChannel(TRACK_NUMBER).getUID()),
stateCaptor.capture());
assertThat(stateCaptor.getValue(),
is(cleared ? UnDefType.UNDEF : new DecimalType(upnpEntryQueue.get(mediaId).getOriginalTrackNumber())));
is(new DecimalType(upnpEntryQueue.get(mediaId).getOriginalTrackNumber()));
Integer originalTrackNumber = upnpEntryQueue.get(mediaId).getOriginalTrackNumber();
if (originalTrackNumber != null) {
assertThat(stateCaptor.getValue(), is(cleared ? UnDefType.UNDEF : new DecimalType(originalTrackNumber)));
is(new DecimalType(originalTrackNumber));
}
}
}