@Test
public void getArtifacts() throws IOException{

    Artifact artifact1 = DataModelFactory.createArtifact("org.axway.test", "artifact1", "1.0.0-SNAPSHOT", "win32",  "jar", "");
    List<Artifact> thirdpartyList = new ArrayList<Artifact>();
    thirdpartyList.add(artifact1);
    stubFor(get(urlEqualTo("/" + ServerAPI.ARTIFACT_RESOURCE + ServerAPI.GET_ALL + "?hasLicense=false"))
            .willReturn(aResponse()
                    .withHeader(HttpHeaders.CONTENT_TYPE, MediaType.APPLICATION_JSON)
                    .withBody(JsonUtils.serialize(thirdpartyList))
                    .withStatus(Status.OK.getStatusCode())));
    Exception exception = null;
    List<Artifact> artifacts = null;
    try{
        artifacts = client.getArtifacts(false);
    }catch (Exception e) {
        exception = e;
    }
    assertNull(exception);
    assertNotNull(artifacts);
    assertEquals(1, artifacts.size());
}