@Test
public void testHDMediaQueryNotAppliesWhenHeightHas2PXMoreThanExpected()
	throws Exception {

	_addConfigs(
		_createAMImageConfigurationEntry(
			"uuid", 450, 800, "http://small.adaptive.com"),
		_createAMImageConfigurationEntry(
			"uuid", 902, 1600, "http://small.hd.adaptive.com"));
	List<MediaQuery> mediaQueries = _mediaQueryProviderImpl.getMediaQueries(
		_fileEntry);
	Assert.assertEquals(mediaQueries.toString(), 2, mediaQueries.size());
	MediaQuery mediaQuery1 = mediaQueries.get(0);
	Assert.assertEquals("http://small.adaptive.com", mediaQuery1.getSrc());
	List<Condition> conditions1 = mediaQuery1.getConditions();
	Assert.assertEquals(conditions1.toString(), 1, conditions1.size());
	_assertCondition(conditions1.get(0), "max-width", "800px");
	MediaQuery mediaQuery2 = mediaQueries.get(1);
	Assert.assertEquals(
		"http://small.hd.adaptive.com", mediaQuery2.getSrc());
	List<Condition> conditions2 = mediaQuery2.getConditions();
	Assert.assertEquals(conditions2.toString(), 2, conditions2.size());
	_assertCondition(conditions2.get(0), "max-width", "1600px");
	_assertCondition(conditions2.get(1), "min-width", "800px");
}