通过任何在线服务器测试FTPS和SFTP

时间:2013-05-14 22:10:02

标签: java testing sftp ftps ftp-server

我正在开发一个提供FTPS和SFTP服务的模块。

要验证我的服务是否正常,我需要提供服务FTPS和/或SFTP请求的在线服务器。

有没有这样好的服务。

谢谢, Vijay Bhore

2 个答案:

答案 0 :(得分:1)

安装自己的。

对于FTP / FTPS,您可以使用FileZilla server

对于SFTP,请参阅Is IIS SFTP natively supported by Windows Server 2012 R2?

答案 1 :(得分:0)

一旦我遇到类似的问题,因此编写了一个在测试期间运行SFTP服务器的JUnit 4规则。它被称为Fake SFTP Server Rule。以下是使用该规则的测试示例:

public class SomeTest {
    @Rule
    public final FakeSftpServerRule sftpServer = new FakeSftpServerRule();

    @Test
    public void testTextFile() {
        //code that uploads the file

        String fileContent = sftpServer.getFileContent("/directory/file.txt", UTF_8);

        //verify content
    }
}