mirror of
https://github.com/apache/cloudstack.git
synced 2025-11-03 04:12:31 +01:00
Use java.io.tmpdir instead of hardcoded /tmp
This commit is contained in:
parent
13b29bac5a
commit
9e90b5393a
@ -31,7 +31,7 @@ public class LocalTemplateDownloaderTest {
|
|||||||
@Test
|
@Test
|
||||||
public void localTemplateDownloaderTest() {
|
public void localTemplateDownloaderTest() {
|
||||||
String url = "file://" + new File("pom.xml").getAbsolutePath();
|
String url = "file://" + new File("pom.xml").getAbsolutePath();
|
||||||
TemplateDownloader td = new LocalTemplateDownloader(null, url, "/tmp", TemplateDownloader.DEFAULT_MAX_TEMPLATE_SIZE_IN_BYTES, null);
|
TemplateDownloader td = new LocalTemplateDownloader(null, url, System.getProperty("java.io.tmpdir"), TemplateDownloader.DEFAULT_MAX_TEMPLATE_SIZE_IN_BYTES, null);
|
||||||
long bytes = td.download(true, null);
|
long bytes = td.download(true, null);
|
||||||
if (!(bytes > 0)) {
|
if (!(bytes > 0)) {
|
||||||
fail("Failed download");
|
fail("Failed download");
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user