Skip to content

Commit

Permalink
build if api github is dead
Browse files Browse the repository at this point in the history
  • Loading branch information
firm1 committed Sep 14, 2016
1 parent 478a1b4 commit f624f42
Showing 1 changed file with 12 additions and 7 deletions.
19 changes: 12 additions & 7 deletions src/test/java/TestModel.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
import javafx.concurrent.Service;
import org.junit.Before;
import org.junit.Test;
import org.apache.http.client.HttpResponseException;

import java.io.File;
import java.io.IOException;
Expand Down Expand Up @@ -356,12 +357,16 @@ public void testImport() throws IOException {
File folder = GithubHttp.unzipOnlineContent (filePath, workspace.getAbsolutePath());
File off = new File(workspace, "france.code-civil");
assertTrue(off.exists());
Content loadContent = GithubHttp.loadManifest(folder.getAbsolutePath(), "steeve", "france.code-civil");
assertNotNull(loadContent);
assertNotNull(loadContent.getTitle());
assertNotNull(loadContent.getFilePath());
assertNotNull(loadContent.getType());
assertNotNull(loadContent.getLicence());
assertTrue(loadContent.getChildren().size() > 0);
try {
Content loadContent = GithubHttp.loadManifest(folder.getAbsolutePath(), "steeve", "france.code-civil");
assertNotNull(loadContent);
assertNotNull(loadContent.getTitle());
assertNotNull(loadContent.getFilePath());
assertNotNull(loadContent.getType());
assertNotNull(loadContent.getLicence());
assertTrue(loadContent.getChildren().size() > 0);
} catch(HttpResponseException hhtpe) {

}
}
}

0 comments on commit f624f42

Please sign in to comment.