@Test(expected = AMRuntimeException.InvalidConfiguration.class)
public void testGetMediaConfigurationError() throws Exception {

	Mockito.when(
		_amImageConfigurationHelper.getAMImageConfigurationEntries(
			Mockito.anyLong(), Mockito.any(Predicate.class))
	).thenThrow(
		AMRuntimeException.InvalidConfiguration.class
	);
	Mockito.when(
		_fileVersion.getMimeType()
	).thenReturn(
		StringUtil.randomString()
	);
	Mockito.when(
		_amImageMimeTypeProvider.isMimeTypeSupported(Mockito.anyString())
	).thenReturn(
		true
	);
	_amImageFinderImpl.getAdaptiveMediaStream(
		amImageQueryBuilder -> amImageQueryBuilder.forFileVersion(
			_fileVersion
		).done());
}