mirror of
https://github.com/corda/corda.git
synced 2025-01-03 19:54:13 +00:00
Delete temporary test file afterwards
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
This commit is contained in:
parent
b246804793
commit
7d7aaa003e
@ -27,13 +27,17 @@ public class Files {
|
||||
throws Exception
|
||||
{
|
||||
File file = File.createTempFile("avian.", null);
|
||||
file.setExecutable(executable);
|
||||
if (executable) {
|
||||
expect(file.canExecute());
|
||||
} else {
|
||||
// Commented out because this will fail on Windows - both on Avian and on OpenJDK
|
||||
// The implementation for Windows considers canExecute() to be the same as canRead()
|
||||
// expect(!file.canExecute());
|
||||
try {
|
||||
file.setExecutable(executable);
|
||||
if (executable) {
|
||||
expect(file.canExecute());
|
||||
} else {
|
||||
// Commented out because this will fail on Windows - both on Avian and on OpenJDK
|
||||
// The implementation for Windows considers canExecute() to be the same as canRead()
|
||||
// expect(!file.canExecute());
|
||||
}
|
||||
} finally {
|
||||
expect(file.delete());
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user