### Question:
TranslatorHelper { public static Translator<InputStream, JsonParser> inputStream2JsonParser(ObjectMapper mapper) { return inputStream2NodeParser(mapper.getFactory()); }  static Translator<byte[], String> bytes2String(); static Translator<byte[], String> bytes2String(Charset charset); static Translator<byte[], String[]> bytes2Lines(Charset charset); static Translator<InputStream, byte[]> inputStream2Bytes(); static Translator<InputStream, String> inputStream2String(Charset charset); static Translator<InputStream, String[]> inputStream2Lines(Charset charset); static Translator<InputStream, JsonNode> inputStream2Json(ObjectMapper mapper); static Translator<InputStream, JsonNode> inputStream2Json(); static Translator<InputStream, T> inputStream2JsonObject(Class<T> type, ObjectMapper mapper); static Translator<InputStream, T> inputStream2JsonObject(Class<T> type); static Translator<InputStream, T> inputStream2XmlObject(Class<T> type, ObjectMapper mapper); static Translator<InputStream, T> inputStream2XmlObject(Class<T> type); static Translator<InputStream, List<T>> inputStream2XmlObjectList(Class<T> type, ObjectMapper mapper); static Translator<InputStream, List<T>> inputStream2XmlObjectList(Class<T> type); static Translator<InputStream, List<T>> inputStream2JsonObjectList(Class<T> type, ObjectMapper mapper); static Translator<InputStream, List<T>> inputStream2JsonObjectList(Class<T> type); static Translator<InputStream, List<T>> inputStream2YamlObjectList(Class<T> type, ObjectMapper mapper); static Translator<InputStream, List<T>> inputStream2YamlObjectList(Class<T> type); static Translator<InputStream, JsonNode> inputStream2Xml(ObjectMapper mapper); static Translator<InputStream, JsonNode> inputStream2Xml(); static Translator<InputStream, JsonNode> inputStream2Yaml(ObjectMapper mapper); static Translator<InputStream, JsonNode> inputStream2Yaml(); static Translator<InputStream, T> inputStream2YamlObject(Class<T> type, ObjectMapper mapper); static Translator<InputStream, T> inputStream2YamlObject(Class<T> type); static Translator<InputStream, JsonParser> inputStream2XmlParser(ObjectMapper mapper); static Translator<InputStream, JsonParser> inputStream2XmlParser(); static Translator<InputStream, JsonParser> inputStream2JsonParser(ObjectMapper mapper); static Translator<InputStream, JsonParser> inputStream2JsonParser(); static Translator<InputStream, JsonParser> inputStream2YamlParser(ObjectMapper mapper); static Translator<InputStream, JsonParser> inputStream2YamlParser(); static Translator<InputStream, T> gzipped(Translator<InputStream, T> original);  }### Answer:
@Test public void testInputStream2JsonParser() throws Exception { var bytes = classpath("translator/test.json").getBytes(UTF_8); var parser = inputStream2JsonParser().translate(new ByteArrayInputStream(bytes)); assertThat(parser.nextToken()).isEqualTo(JsonToken.START_OBJECT); assertThat(parser.nextToken()).isEqualTo(JsonToken.FIELD_NAME); assertThat(parser.currentName()).isEqualTo("glossary"); assertThat(parser.nextToken()).isEqualTo(JsonToken.START_OBJECT); }