Fix AsyncFileTest
This commit is contained in:
parent
333d3bc122
commit
602e98c6c3
@ -59,9 +59,9 @@ public class AsyncFileTest {
|
|||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void givenPathAndContent_whenWritesToFileWithFuture_thenCorrect() throws IOException, ExecutionException, InterruptedException {
|
public void givenPathAndContent_whenWritesToFileWithFuture_thenCorrect() throws IOException, ExecutionException, InterruptedException {
|
||||||
String fileName = UUID.randomUUID().toString();
|
String fileName = "temp";
|
||||||
Path path = Paths.get(Paths.get(HOME));
|
Path path = Paths.get(fileName);
|
||||||
AsynchronousFileChannel fileChannel = AsynchronousFileChannel.open(path, StandardOpenOption.WRITE, StandardOpenOption.CREATE,StandardOpenOption.DELETE_ON_CLOSE);
|
AsynchronousFileChannel fileChannel = AsynchronousFileChannel.open(path, StandardOpenOption.WRITE, StandardOpenOption.CREATE);
|
||||||
|
|
||||||
ByteBuffer buffer = ByteBuffer.allocate(1024);
|
ByteBuffer buffer = ByteBuffer.allocate(1024);
|
||||||
long position = 0;
|
long position = 0;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user