### Question:
RapidEyeMetadata extends XmlMetadata { public int getPixelFormat() { RapidEyeConstants.PixelFormat dataType = RapidEyeConstants.PixelFormat.UNSIGNED_INTEGER; MetadataElement currentElement; if ((currentElement = rootElement.getElement(RapidEyeConstants.TAG_EARTH_OBSERVATION_META_DATA)) != null) { String pixelFormat = currentElement.getAttributeString(RapidEyeConstants.TAG_PIXEL_FORMAT, ""); try { dataType = RapidEyeConstants.PixelFormat.valueOf(pixelFormat); } catch (Exception e) { logger.warning(String.format("Invalid pixel format. Found %s, expected 16U or SI.", pixelFormat)); } } return dataType.getDataType(); } RapidEyeMetadata(String name); @Override String getFileName(); @Override int getNumBands(); @Override String getProductName(); @Override String getFormatName(); @Override String getMetadataProfile(); @Override String getProductDescription(); @Override int getRasterWidth(); @Override int getRasterHeight(); String getBrowseFileName(); String getMaskFileName(); @Override String[] getRasterFileNames(); SpatialReferenceSystem getReferenceSystem(); ProductData.UTC getProductStartTime(); ProductData.UTC getProductEndTime(); ProductData.UTC getCenterTime(); float getScaleFactor(int bandIndex); int getPixelFormat(); float[] getCornersLatitudes(); float[] getCornersLongitudes(); RationalCoefficients getRationalPolinomialCoefficients();  }### Answer:
@Test public void testGetPixelFormat() throws Exception { assertEquals(21, metadata.getPixelFormat()); }