Revision 45348
Added by Claudio Atzori about 7 years ago
DownloadWorkerTest.java | ||
---|---|---|
7 | 7 |
import eu.dnetlib.data.objectstore.modular.ObjectStoreRecord; |
8 | 8 |
import eu.dnetlib.data.objectstore.modular.connector.ObjectStore; |
9 | 9 |
import eu.dnetlib.data.objectstore.rmi.Protocols; |
10 |
import org.bouncycastle.jce.provider.BouncyCastleProvider; |
|
10 |
|
|
11 | 11 |
import org.junit.Before; |
12 |
import org.junit.Ignore; |
|
12 | 13 |
import org.junit.Test; |
13 | 14 |
import org.junit.runner.RunWith; |
14 | 15 |
import org.mockito.Mock; |
15 |
import org.mockito.runners.MockitoJUnitRunner;
|
|
16 |
import org.mockito.junit.MockitoJUnitRunner;
|
|
16 | 17 |
|
17 | 18 |
import static org.junit.Assert.assertEquals; |
18 | 19 |
import static org.mockito.Matchers.any; |
... | ... | |
31 | 32 |
|
32 | 33 |
@Before |
33 | 34 |
public void prepare() throws Exception{ |
34 |
Security.insertProviderAt(new BouncyCastleProvider(),1); |
|
35 |
System.setProperty("https.protocols", "TLSv1,TLSv1.1,TLSv1.2"); |
|
35 |
//Security.insertProviderAt(new BouncyCastleProvider(),1);
|
|
36 |
//System.setProperty("https.protocols", "TLSv1,TLSv1.1,TLSv1.2");
|
|
36 | 37 |
reportMap = new DownloadReportMap(); |
37 | 38 |
|
38 | 39 |
when(objectStore.feedObjectRecord(any(ObjectStoreRecord.class))).thenReturn("OK"); |
... | ... | |
47 | 48 |
}); |
48 | 49 |
} |
49 | 50 |
|
51 |
@Ignore |
|
50 | 52 |
@Test |
51 | 53 |
public void testSSL(){ |
52 | 54 |
String url = "https://econstor.eu/bitstream/10419/45606/1/658945068.pdf"; |
Also available in: Unified diff
migrated to dnet45