SignatureFormatParser { public static SignatureLevel parse(String v) { if (v != null) { return SignatureLevel.valueByName(v); } return null; } private  SignatureFormatParser(); static SignatureLevel parse(String v); static String print(SignatureLevel v);  }
@Test public void parseUnknown() { Exception exception = assertThrows(IllegalArgumentException.class, () -> { SignatureFormatParser.parse("non-value"); }); assertEquals("No enum constant eu.europa.esig.dss.enumerations.SignatureLevel.non_value", exception.getMessage()); }