Skip to content

Commit

Permalink
Two unit tests has been changed into manual run integration test.
Browse files Browse the repository at this point in the history
  • Loading branch information
teg committed Jul 25, 2023
1 parent a0e2f4a commit 6f6979c
Showing 1 changed file with 28 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,30 @@
*/
public class ArcSourceTest {


/*
* These tests depend on external resource and one of them is not on net anymore.
* The two test has been changed into a manual integration test.
*
*/
public static void main(String[] args) {
try {
testHTTPSURL();
testHTTSURL();

}
catch(Exception e) {
System.out.println("Integration test error for testHTTPSURL() or testHTTSURL()");
e.printStackTrace();

}


}




@Test
public void testPath() throws IOException {
String known = Objects.requireNonNull(Thread.currentThread().getContextClassLoader().getResource("logback-test.xml")).getPath();
Expand All @@ -46,8 +70,8 @@ public void testFileURL() throws IOException {
assertTrue("Getting file system content from '" + known + " should work", content.startsWith("<?xml"));
}

@Test
public void testHTTSURL() throws IOException {

public static void testHTTSURL() throws IOException {
String known = "http://bash.org/";

ArcSource source = ArcSource.create(known);
Expand All @@ -56,8 +80,8 @@ public void testHTTSURL() throws IOException {
assertTrue("Getting file system content from '" + known + " should work", content.contains("<html"));
}

@Test
public void testHTTPSURL() throws IOException {

public static void testHTTPSURL() throws IOException {
String known = "https://www.kb.dk/";

ArcSource source = ArcSource.create(known);
Expand Down

0 comments on commit 6f6979c

Please sign in to comment.