### Question:
RepresentationFormatRepository { public InputFormat inputFormat( MediaType type ) { if ( type == null ) { return useDefault(); } RepresentationFormat format = formats.get( type ); if ( format != null ) { return format; } format = formats.get( new MediaType( type.getType(), type.getSubtype() ) ); if ( format != null ) { return format; } return useDefault( type ); } RepresentationFormatRepository( AbstractNeoServer injectorProvider ); OutputFormat outputFormat( List<MediaType> acceptable, URI baseUri,
            MultivaluedMap<String,String> requestHeaders ); InputFormat inputFormat( MediaType type );  }### Answer:
@Test public void canProvideJsonFormat() { assertNotNull( repository.inputFormat( MediaType.valueOf( "application/json" ) ) ); }
@Test public void canProvideUTF8EncodedJsonFormat() { assertNotNull( repository.inputFormat( MediaType.valueOf( "application/json;charset=UTF-8" ) ) ); }
@Test( expected = MediaTypeNotSupportedException.class ) public void canNotGetInputFormatBasedOnWildcardMediaType() throws Exception { InputFormat format = repository.inputFormat( MediaType.WILDCARD_TYPE ); format.readValue( "foo" ); fail( "Got InputFormat based on wild card type: " + format ); }