package study.hard.javalib.file;

import java.io.File;
import java.io.IOException;

import org.junit.After;
import org.junit.Before;
import org.junit.Test;

public class FileTest {

	FileHandler fileHandler;
	File tempFile;

	@Before
	public void setUp() {
		fileHandler = new FileHandler();
	}

	@Test
	public void testCreateTempFile() throws IOException {
		tempFile = fileHandler.getTempFile("TEST_TEMP_FILE.txt");
		System.out.println("Absolute path of temporary file: " + tempFile.getAbsolutePath());
	}

	@After
	public void clean() {
		tempFile.delete();
	}
}

@@ -503,16 +503,177 @@
 ));%0A%09%7D%0A%0A
+%09@Test%0A%09public void testGetTempDirectoryPath() %7B%0A%09%09File tempDirectory = new File(System.getProperty(%22java.io.tmpdir%22));%0A%09%09System.out.println(tempDirectory);%0A%09%7D%0A%0A
 %09@After%0A
@@ -695,16 +695,43 @@
 ean() %7B%0A
+%09%09if (tempFile != null) %7B%0A%09
 %09%09tempFi
@@ -743,13 +743,17 @@
 lete();%0A
+%09%09%7D%0A
 %09%7D%0A%7D%0A

Add a test case to get temp directory.