### Question:
IntegrationProcessStatus { @JsonIgnore public boolean isFinished() { return status != null && status.isFinished(); } @JsonCreator protected  IntegrationProcessStatus(@JsonProperty("status") Status status,
                                       @JsonProperty("started") ZonedDateTime started,
                                       @JsonProperty("finished") ZonedDateTime finished,
                                       @JsonProperty("links") Map<String, String> links); Status getStatus(); ZonedDateTime getStarted(); ZonedDateTime getFinished(); @JsonIgnore boolean isFinished(); @JsonIgnore boolean isFailed(); @JsonIgnore String getUri(); @JsonIgnore String getId(); @Override String toString(); static final String URI; }### Answer:
@Test public void testIsFinishedOnError() throws Exception { final IntegrationProcessStatus process = new IntegrationProcessStatus(new Status(ERROR.name(), "", ""), now(), now(), Collections.emptyMap()); assertThat(process.isFinished(), is(true)); }
@Test public void testIsFinishedOnSynchronized() throws Exception { final IntegrationProcessStatus process = new IntegrationProcessStatus(new Status(SYNCHRONIZED.name(), "", ""), now(), now(), Collections.emptyMap()); assertThat(process.isFinished(), is(true)); }
@Test public void testIsFinishedOnUploading() throws Exception { final IntegrationProcessStatus process = new IntegrationProcessStatus(new Status(UPLOADING.name(), "", ""), now(), now(), Collections.emptyMap()); assertThat(process.isFinished(), is(false)); }
@Test public void testIsFinishedOnNullCode() throws Exception { final IntegrationProcessStatus process = new IntegrationProcessStatus(new Status(null, "", ""), now(), now(), Collections.emptyMap()); assertThat(process.isFinished(), is(false)); }
@Test public void testIsFinishedOnUnknownCode() throws Exception { final IntegrationProcessStatus process = new IntegrationProcessStatus(new Status("unknown code", "", ""), now(), now(), Collections.emptyMap()); assertThat(process.isFinished(), is(false)); }