src/test/java/org/embulk/output/sftp/TestSftpFileOutputPlugin.java in embulk-output-sftp-0.2.1 vs src/test/java/org/embulk/output/sftp/TestSftpFileOutputPlugin.java in embulk-output-sftp-0.2.2
- old
+ new
@@ -1,9 +1,8 @@
package org.embulk.output.sftp;
import com.google.common.base.Charsets;
-import com.google.common.base.Optional;
import com.google.common.collect.Lists;
import com.google.common.io.Resources;
import com.jcraft.jsch.JSchException;
import org.apache.commons.vfs2.FileObject;
import org.apache.commons.vfs2.FileSystemException;
@@ -60,10 +59,11 @@
import java.nio.file.Paths;
import java.security.PublicKey;
import java.util.Arrays;
import java.util.Collections;
import java.util.List;
+import java.util.Optional;
import java.util.Random;
import java.util.concurrent.TimeoutException;
import static com.google.common.io.Files.readLines;
import static org.embulk.spi.type.Types.BOOLEAN;
@@ -329,19 +329,19 @@
PluginTask task = config.loadConfig(PluginTask.class);
assertEquals(HOST, task.getHost());
assertEquals(22, task.getPort());
assertEquals(USERNAME, task.getUser());
- assertEquals(Optional.absent(), task.getPassword());
- assertEquals(Optional.absent(), task.getSecretKeyFilePath());
+ assertEquals(Optional.empty(), task.getPassword());
+ assertEquals(Optional.empty(), task.getSecretKeyFilePath());
assertEquals("", task.getSecretKeyPassphrase());
assertEquals(true, task.getUserDirIsRoot());
assertEquals(600, task.getSftpConnectionTimeout());
assertEquals(5, task.getMaxConnectionRetry());
assertEquals(pathPrefix, task.getPathPrefix());
assertEquals("txt", task.getFileNameExtension());
assertEquals("%03d.%02d.", task.getSequenceFormat());
- assertEquals(Optional.absent(), task.getProxy());
+ assertEquals(Optional.empty(), task.getProxy());
}
@Test
public void testConfigValuesIncludingProxy()
{