Description: skipping tests that attempt to get files over the network
Author: Pierre Gruet <pgt@debian.org>
Forwarded: not-needed
Last-Update: 2022-03-26

--- a/src/test/java/org/broadinstitute/http/nio/GitHubResourcesIntegrationTest.java
+++ b/src/test/java/org/broadinstitute/http/nio/GitHubResourcesIntegrationTest.java
@@ -25,7 +25,7 @@
         };
     }
 
-    @Test(dataProvider = "getDocsFilesForTesting")
+    @Test(enabled = false, dataProvider = "getDocsFilesForTesting")
     public void testGitHubResourcesExists(final String fileName) throws Exception {
         final HttpURLConnection connection = (HttpURLConnection)
                 getGithubPagesFileUrl(fileName).openConnection();
@@ -43,7 +43,7 @@
         Assert.assertTrue(Files.exists(getLocalDocsFilePath(fileName)));
     }
 
-    @Test(dataProvider = "getDocsFilesForTesting")
+    @Test(enabled = false, dataProvider = "getDocsFilesForTesting")
     public void testGithubAndDocsResourcesAreEqual(final String fileName) throws Exception {
         // 1. read the local file
         final byte[] local = Files.readAllBytes(getLocalDocsFilePath(fileName));
--- a/src/test/java/org/broadinstitute/http/nio/HttpAbstractFileSystemProviderUnitTest.java
+++ b/src/test/java/org/broadinstitute/http/nio/HttpAbstractFileSystemProviderUnitTest.java
@@ -144,14 +144,14 @@
         };
     }
 
-    @Test(dataProvider= "deniedAccess", expectedExceptions = AccessDeniedException.class)
+    @Test(enabled = false, dataProvider= "deniedAccess", expectedExceptions = AccessDeniedException.class)
     public void testCheckAccessDenied(final AccessMode deniedAcces) throws Exception {
         final HttpsFileSystemProvider https = new HttpsFileSystemProvider();
         final HttpPath path = https.getPath(getGithubPagesFileUrl("file1.txt").toURI());
         https.checkAccess(path, deniedAcces);
     }
 
-    @Test
+    @Test(enabled = false)
     public void testCheckAccessRead() throws Exception {
         final HttpsFileSystemProvider https = new HttpsFileSystemProvider();
         final HttpPath path = https.getPath(getGithubPagesFileUrl("file1.txt").toURI());
--- a/src/test/java/org/broadinstitute/http/nio/HttpUtilsUnitTest.java
+++ b/src/test/java/org/broadinstitute/http/nio/HttpUtilsUnitTest.java
@@ -48,7 +48,7 @@
         HttpUtils.setRangeRequest(null, 10, 100);
     }
 
-    @Test(dataProvider = "getDocsFilesForTesting", dataProviderClass = GitHubResourcesIntegrationTest.class)
+    @Test(enabled = false, dataProvider = "getDocsFilesForTesting", dataProviderClass = GitHubResourcesIntegrationTest.class)
     public void testExistingUrls(final String fileName) throws IOException {
         Assert.assertTrue(HttpUtils.exists(getGithubPagesFileUrl(fileName)));
     }
@@ -70,4 +70,4 @@
         final URL nonExistant = URI.create(urlString).toURL();
         Assert.assertFalse(HttpUtils.exists(nonExistant));
     }
-}
\ No newline at end of file
+}
--- a/src/test/java/org/broadinstitute/http/nio/URLSeekableByteChannelUnitTest.java
+++ b/src/test/java/org/broadinstitute/http/nio/URLSeekableByteChannelUnitTest.java
@@ -29,12 +29,12 @@
     public static final String BIG_TXT_GOOGLE = "https://storage.googleapis.com/hellbender/test/resources/nio/big.txt";
     public static final String BIG_TXT_LOCAL = "testdata/big.txt";
 
-    @Test(expectedExceptions = FileNotFoundException.class)
+    @Test(enabled = false, expectedExceptions = FileNotFoundException.class)
     public void testNonExistentUrl() throws Exception {
         new URLSeekableByteChannel(getGithubPagesFileUrl("not_existent.txt"));
     }
 
-    @Test
+    @Test(enabled = false)
     public void testNonWritableChannelExceptions() throws Exception {
         try (final URLSeekableByteChannel channel =
                 new URLSeekableByteChannel(getGithubPagesFileUrl("file1.txt"))) {
@@ -46,7 +46,7 @@
         }
     }
 
-    @Test(dataProvider = "getDocsFilesForTesting", dataProviderClass = GitHubResourcesIntegrationTest.class)
+    @Test(enabled = false, dataProvider = "getDocsFilesForTesting", dataProviderClass = GitHubResourcesIntegrationTest.class)
     public void testSize(final String fileName) throws Exception {
         final URL urlFile = getGithubPagesFileUrl(fileName);
         final Path localFile = getLocalDocsFilePath(fileName);
@@ -56,7 +56,7 @@
         }
     }
 
-    @Test(dataProvider = "getDocsFilesForTesting", dataProviderClass = GitHubResourcesIntegrationTest.class)
+    @Test(enabled = false, dataProvider = "getDocsFilesForTesting", dataProviderClass = GitHubResourcesIntegrationTest.class)
     public void testSizeAfterRead(final String fileName) throws Exception {
         final URL urlFile = getGithubPagesFileUrl(fileName);
         final Path localFile = getLocalDocsFilePath(fileName);
@@ -73,7 +73,7 @@
         }
     }
 
-    @Test(dataProvider = "getDocsFilesForTesting", dataProviderClass = GitHubResourcesIntegrationTest.class)
+    @Test(enabled = false, dataProvider = "getDocsFilesForTesting", dataProviderClass = GitHubResourcesIntegrationTest.class)
     public void testCachedSize(final String fileName) throws Exception {
         final URL urlFile = getGithubPagesFileUrl(fileName);
         final Path localFile = getLocalDocsFilePath(fileName);
@@ -93,7 +93,7 @@
         }
     }
 
-    @Test
+    @Test(enabled = false)
     public void testGetPosition() throws Exception {
         // open channel
         try (final URLSeekableByteChannel channel =
@@ -110,7 +110,7 @@
         }
     }
 
-    @Test(expectedExceptions = IllegalArgumentException.class)
+    @Test(enabled = false, expectedExceptions = IllegalArgumentException.class)
     public void testIllegalPosition() throws Exception {
         new URLSeekableByteChannel(getGithubPagesFileUrl("file1.txt")).position(-1);
     }
@@ -126,7 +126,7 @@
                         }).iterator();
     }
 
-    @Test(dataProvider = "seekData")
+    @Test(enabled = false, dataProvider = "seekData")
     public void testSeekBeforeRead(final URL testUrl, final long position, final Path localFile)
             throws Exception {
         try (final URLSeekableByteChannel actual = new URLSeekableByteChannel(testUrl);
@@ -137,7 +137,7 @@
         }
     }
 
-    @Test(dataProvider = "seekData")
+    @Test(enabled = false, dataProvider = "seekData")
     public void testSeekToBeginning(final URL testUrl, final long position, final Path localFile)
             throws Exception {
         try (final URLSeekableByteChannel actual = new URLSeekableByteChannel(testUrl);
@@ -149,7 +149,7 @@
         }
     }
 
-    @Test(dataProvider = "seekData")
+    @Test(enabled = false, dataProvider = "seekData")
     public void testSeekToSamePosition(final URL testUrl, final long position, final Path localFile)
             throws Exception {
         try (final URLSeekableByteChannel actual = new URLSeekableByteChannel(testUrl);
@@ -161,7 +161,7 @@
         }
     }
 
-    @Test(dataProvider = "seekData")
+    @Test(enabled = false, dataProvider = "seekData")
     public void testSeekShouldReopen(final URL testUrl, final long position, final Path localFile)
             throws Exception {
         try (final URLSeekableByteChannel actual = new URLSeekableByteChannel(testUrl);
@@ -188,7 +188,7 @@
                 "different byte[] after read");
     }
 
-    @Test
+    @Test(enabled = false)
     public void testClose() throws Exception {
         // open channel
         final URLSeekableByteChannel channel = new URLSeekableByteChannel(
@@ -208,7 +208,7 @@
         Assert.assertThrows(ClosedChannelException.class, () -> channel.read(ByteBuffer.allocate(1)));
     }
 
-    @Test
+    @Test(enabled = false)
     public void testPositionOnGoogleFile() throws IOException {
         URL url = new URL(LARGE_FILE_ON_GOOGLE);
         try(URLSeekableByteChannel channel = new URLSeekableByteChannel(url)) {
@@ -217,7 +217,7 @@
         }
     }
 
-    @Test(timeOut=10_000L) //time out if it's taking over 10 seconds to read, that indicates we're probably not skipping correctly
+    @Test(enabled = false, timeOut=10_000L) //time out if it's taking over 10 seconds to read, that indicates we're probably not skipping correctly
     public void testReadAtEndOfLargeFileIsFast() throws IOException {
         URL url = new URL(LARGE_FILE_ON_GOOGLE);
         try(URLSeekableByteChannel channel = new URLSeekableByteChannel(url)) {
@@ -234,7 +234,7 @@
         return new Object[][]{{100},{1_000}, {10_000}, {100_000}, {1_000_000}};
     }
 
-    @Test(dataProvider = "stepSize")
+    @Test(enabled = false, dataProvider = "stepSize")
     public void testDataIsConsistentForward(int stepSize) throws IOException {
         URL url = new URL(BIG_TXT_GOOGLE);
         try(final URLSeekableByteChannel remote = new URLSeekableByteChannel(url);
@@ -257,7 +257,7 @@
         };
     }
 
-    @Test(dataProvider = "steps")
+    @Test(enabled = false, dataProvider = "steps")
     public void testDataIsConsistentWhileSeeking(List<Integer> positions) throws IOException {
         URL url = new URL(BIG_TXT_GOOGLE);
         final int readlength = 100;
