Skip to content

Commit

Permalink
change cache location
Browse files Browse the repository at this point in the history
Signed-off-by: tobiasKaminsky <tobias@kaminsky.me>
  • Loading branch information
tobiasKaminsky committed Jul 24, 2019
1 parent 788b3e7 commit 0cd0a86
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion src/androidTest/java/com/owncloud/android/AbstractIT.java
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,17 @@ public static void beforeAll() {
}

public String createFile(String name) throws IOException {
File tempDir = context.getFilesDir();
File tempDir = context.getExternalCacheDir();

if (tempDir == null) {
throw new IOException("Temp dir is null");
}

if (!tempDir.exists()) {
if (!tempDir.mkdirs()) {
throw new IOException("Cannot create temp dir: " + tempDir.getAbsolutePath());
}
}

File file = new File(tempDir + File.separator + name);

Expand Down

0 comments on commit 0cd0a86

Please sign in to comment.