### Question:
JsonArray extends JsonValue implements Iterable<Object>, Serializable { public static JsonArray fromJson(String s) { try { return JacksonTransformers.stringToJsonArray(s); } catch (Exception e) { throw InvalidArgumentException.fromMessage("Cannot convert string to JsonArray", e); } } private  JsonArray(); private  JsonArray(int initialCapacity); static JsonArray create(); static JsonArray create(int initialCapacity); static JsonArray from(Object... items); static JsonArray from(List<?> items); static JsonArray fromJson(String s); static JsonArray fromJson(byte[] s); Object get(int index); JsonArray add(Object value); JsonArray addNull(); JsonArray add(String value); String getString(int index); JsonArray add(long value); Long getLong(int index); JsonArray add(int value); Integer getInt(int index); JsonArray add(double value); Double getDouble(int index); JsonArray add(boolean value); boolean getBoolean(int index); JsonArray add(JsonObject value); JsonArray add(Map<String, ?> value); JsonObject getObject(int index); JsonArray add(JsonArray value); JsonArray add(List<?> value); JsonArray add(Number value); JsonArray getArray(int index); BigInteger getBigInteger(int index); BigDecimal getBigDecimal(int index); Number getNumber(int index); List<Object> toList(); boolean isEmpty(); int size(); boolean contains(Object value); @Override Iterator<Object> iterator(); @Override String toString(); byte[] toBytes(); @Override boolean equals(Object o); @Override int hashCode();  }### Answer:
@Test void shouldConvertNullStringToNull() { assertNull(JsonArray.fromJson("null")); }
@Test void shouldFailToConvertBadJsonString() { String badJson = "This is not \"JSON\"!"; assertThrows(InvalidArgumentException.class, () -> JsonArray.fromJson(badJson)); }
@Test void shouldFailToConvertNonArrayJson() { String bad1 = "true"; String bad2 = "123"; String bad3 = "\"string\""; String bad4 = "{\"some\": \"value\"}"; assertThrows(InvalidArgumentException.class, () -> JsonArray.fromJson(bad1)); assertThrows(InvalidArgumentException.class, () -> JsonArray.fromJson(bad2)); assertThrows(InvalidArgumentException.class, () -> JsonArray.fromJson(bad3)); assertThrows(InvalidArgumentException.class, () -> JsonArray.fromJson(bad4)); }