git.annexia.org
/
libguestfs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
db98ac0
)
java: Remove old test file if one was left around.
author
Richard W.M. Jones
<rjones@redhat.com>
Wed, 2 Mar 2011 05:10:31 +0000
(
05:10
+0000)
committer
Richard W.M. Jones
<rjones@redhat.com>
Wed, 2 Mar 2011 05:11:55 +0000
(
05:11
+0000)
If a test.img file was left over from a previous run, then it
would cause the subsequent test to fail. Therefore remove any
old test.img file.
java/t/GuestFS010Basic.java
patch
|
blob
|
history
diff --git
a/java/t/GuestFS010Basic.java
b/java/t/GuestFS010Basic.java
index
f4778dc
..
137fad3
100644
(file)
--- a/
java/t/GuestFS010Basic.java
+++ b/
java/t/GuestFS010Basic.java
@@
-24,6
+24,10
@@
public class GuestFS010Basic
public static void main (String[] argv)
{
try {
+ // Delete any previous test file if one was left around.
+ File old = new File ("test.img");
+ old.delete ();
+
RandomAccessFile f = new RandomAccessFile ("test.img", "rw");
f.setLength (500 * 1024 * 1024);
f.close ();