File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
src/test/java/org/gluster/test Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change 6
6
7
7
import org .apache .hadoop .fs .glusterfs .GlusterFUSEInputStream ;
8
8
import org .apache .hadoop .fs .glusterfs .GlusterFUSEOutputStream ;
9
+ import org .junit .After ;
9
10
import org .junit .Before ;
10
11
import org .junit .Test ;
11
12
@@ -16,11 +17,16 @@ public class TestGlusterFuseInputStream{
16
17
public void create () throws Exception {
17
18
//setup: no need for gluster specific path, since its just reading from local path
18
19
infile =File .createTempFile ("TestGlusterFuseInputStream" +System .currentTimeMillis (),"txt" ).getAbsolutePath ();
19
- final GlusterFUSEOutputStream stream = new GlusterFUSEOutputStream (infile ,true );
20
+ new File (infile ).deleteOnExit ();
21
+ final GlusterFUSEOutputStream stream = new GlusterFUSEOutputStream (infile ,true );
20
22
stream .write ("hello there, certainly, there is some data in this stream" .getBytes ());
21
23
stream .close ();
22
24
}
23
25
26
+ @ After
27
+ public void cleanUp () throws Exception {
28
+ new File (infile ).delete ();
29
+ }
24
30
@ Test
25
31
public void testDoubleClose () throws Exception {
26
32
//test
You can’t perform that action at this time.
0 commit comments