| | |
| | | public class ConfigHandlerTest { |
| | | @Test |
| | | void readWriteTest() throws IOException { |
| | | File origConfigFile = new File(System.getProperty("user.home"), ".borgbutler-orig.json"); |
| | | File workingDir = ConfigurationHandler.getInstance().getWorkingDir(); |
| | | File origConfigFile = new File(workingDir, ".borgbutler-orig.json"); |
| | | FileUtils.copyFile(ConfigurationHandler.getInstance().getConfigFile(), origConfigFile); |
| | | Configuration configuration = ConfigurationHandler.getConfiguration(); |
| | | ConfigurationHandler.getInstance().write(); |
| | | FileUtils.copyFile(origConfigFile, ConfigurationHandler.getInstance().getConfigFile()); |
| | | } |