- package osm.surveyor.task.plateau;
-
- import static org.junit.jupiter.api.Assertions.*;
-
- import java.nio.file.Path;
-
- import org.junit.jupiter.api.AfterAll;
- import org.junit.jupiter.api.AfterEach;
- import org.junit.jupiter.api.BeforeAll;
- import org.junit.jupiter.api.BeforeEach;
- import org.junit.jupiter.api.DisplayName;
- import org.junit.jupiter.api.Test;
- import org.springframework.beans.factory.annotation.Autowired;
- import org.springframework.boot.test.context.SpringBootTest;
- import org.springframework.util.FileSystemUtils;
-
- @SpringBootTest
- class PlateauServiceTest {
-
- @Autowired
- PlateauService service;
-
- private static final String dirStr = "plateau-data"; // task-bldg.plateau.dir=plateau-data
-
- @BeforeAll
- static void setUpBeforeClass() throws Exception {
- Path dir = Path.of(dirStr);
- FileSystemUtils.deleteRecursively(dir);
- }
-
- @AfterAll
- static void tearDownAfterClass() throws Exception {
- }
-
- @BeforeEach
- void setUp() throws Exception {
- }
-
- @AfterEach
- void tearDown() throws Exception {
- }
-
- @Test
- @DisplayName("'PlateauService.getPlateauStatus() ['./plateau-data' is not exists.]")
- void testGetPlateauStatus() throws Exception {
- Boolean ret = service.getPlateauStatus();
- assertFalse(ret);
- }
-
- }