### Question:
ActionError implements Serializable { public static ActionError from(Sc2Api.ActionError sc2ApiActionError) { require("sc2api action error", sc2ApiActionError); return new ActionError(sc2ApiActionError); } private  ActionError(Sc2Api.ActionError sc2ApiActionError); static ActionError from(Sc2Api.ActionError sc2ApiActionError); Optional<Tag> getUnitTag(); Optional<Ability> getAbility(); ActionResult getActionResult(); @Override boolean equals(Object o); @Override int hashCode(); @Override String toString();  }### Answer:
@Test void throwsExceptionWhenSc2ApiActionErrorIsNull() { assertThatExceptionOfType(IllegalArgumentException.class) .isThrownBy(() -> ActionError.from(nothing())) .withMessage("sc2api action error is required"); }
@Test void convertsSc2ApiActionErrorToActionError() { assertThatAllFieldsAreConverted(ActionError.from(sc2ApiActionError())); }
@Test void throwsExceptionWhenActionResultIsNotProvided() { assertThatExceptionOfType(IllegalArgumentException.class) .isThrownBy(() -> ActionError.from(without( () -> sc2ApiActionError().toBuilder(), Sc2Api.ActionError.Builder::clearResult).build())) .withMessage("action result is required"); }