Cleaned up the IOUtilsTest class a bit
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful

This commit is contained in:
Gregory Ballantine 2022-05-03 00:17:50 -04:00
parent 204a5e15f1
commit 347211d566

View File

@ -2,16 +2,19 @@ package tech.bitgoblin.io;
import static org.junit.Assert.assertTrue;
import org.junit.AfterClass;
import org.junit.Test;
import java.io.File;
public class IOUtilsTest {
private static String testDir = "test-temp";
@Test
public void shouldCreateDirectory() {
IOUtils.createDirectory("test-temp.txt");
assertTrue(new File("test-temp.txt").exists());
IOUtils.createDirectory(testDir);
assertTrue(new File(testDir).exists());
}
@Test
@ -25,4 +28,9 @@ public class IOUtilsTest {
IOUtils.resolveTilda("~test");
}
@AfterClass
public static void cleanup() {
new File(testDir).delete();
}
}