From a492c1ac441b4836b5399280253747eae6d43ae2 Mon Sep 17 00:00:00 2001 From: Mattia Bertorello Date: Thu, 18 Jul 2019 12:17:04 +0200 Subject: [PATCH] Fix test about the contributions downloader --- .../cc/arduino/contributions/GzippedJsonDownloaderTest.java | 4 +++- app/test/cc/arduino/contributions/JsonDownloaderTest.java | 3 ++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/app/test/cc/arduino/contributions/GzippedJsonDownloaderTest.java b/app/test/cc/arduino/contributions/GzippedJsonDownloaderTest.java index e1e231acd3a..745ccb1dd5b 100644 --- a/app/test/cc/arduino/contributions/GzippedJsonDownloaderTest.java +++ b/app/test/cc/arduino/contributions/GzippedJsonDownloaderTest.java @@ -38,7 +38,9 @@ public void tearDown() throws Exception { @Test public void testJsonDownload() throws Exception { - new GZippedJsonDownloader(downloader, new URL("http://downloads.arduino.cc/libraries/library_index.json"), new URL("http://downloads.arduino.cc/libraries/library_index.json.gz")).download(tempFile, new MultiStepProgress(1), "", new NoopProgressListener()); + new GZippedJsonDownloader(downloader, new URL("http://downloads.arduino.cc/libraries/library_index.json"), + new URL("http://downloads.arduino.cc/libraries/library_index.json.gz")) + .download(tempFile, new MultiStepProgress(1), "", new NoopProgressListener(), true); InputStream indexIn = new FileInputStream(tempFile); ObjectMapper mapper = new ObjectMapper(); diff --git a/app/test/cc/arduino/contributions/JsonDownloaderTest.java b/app/test/cc/arduino/contributions/JsonDownloaderTest.java index ebf3c0913ce..bdb64325f59 100644 --- a/app/test/cc/arduino/contributions/JsonDownloaderTest.java +++ b/app/test/cc/arduino/contributions/JsonDownloaderTest.java @@ -38,7 +38,8 @@ public void tearDown() throws Exception { @Test public void testJsonDownload() throws Exception { - new JsonDownloader(downloader, new URL("http://downloads.arduino.cc/libraries/library_index.json")).download(tempFile, new MultiStepProgress(1), "", new NoopProgressListener()); + new JsonDownloader(downloader, new URL("http://downloads.arduino.cc/libraries/library_index.json")) + .download(tempFile, new MultiStepProgress(1), "", new NoopProgressListener(), true); InputStream indexIn = new FileInputStream(tempFile); ObjectMapper mapper = new ObjectMapper();