diff options
author | Péter Dimitrov <[email protected]> | 2018-03-27 13:21:44 +0200 |
---|---|---|
committer | Péter Dimitrov <[email protected]> | 2018-03-28 10:19:38 +0200 |
commit | 6fc2b7bf5eb331fdc1c0fb93758dad5a741da4fa (patch) | |
tree | fbd74a42c01c4936b691060e1d6ed55b489c1fdd /lib | |
parent | 8a805f67cff9bf04188d38dca3f0031455c73e90 (diff) | |
download | otp-6fc2b7bf5eb331fdc1c0fb93758dad5a741da4fa.tar.gz otp-6fc2b7bf5eb331fdc1c0fb93758dad5a741da4fa.tar.bz2 otp-6fc2b7bf5eb331fdc1c0fb93758dad5a741da4fa.zip |
common_test: Remove dependency to inets ftp
- Update ct_ftp to use the new FTP application.
Change-Id: I84223107361132ea3144cdf7421738c4bebffa40
Diffstat (limited to 'lib')
-rw-r--r-- | lib/common_test/doc/src/ct_ftp.xml | 6 | ||||
-rw-r--r-- | lib/common_test/src/common_test.app.src | 1 | ||||
-rw-r--r-- | lib/common_test/src/ct_ftp.erl | 8 |
3 files changed, 7 insertions, 8 deletions
diff --git a/lib/common_test/doc/src/ct_ftp.xml b/lib/common_test/doc/src/ct_ftp.xml index e8c6f72db7..a6f01dd58e 100644 --- a/lib/common_test/doc/src/ct_ftp.xml +++ b/lib/common_test/doc/src/ct_ftp.xml @@ -33,13 +33,11 @@ <file>ct_ftp.xml</file> </header> <module>ct_ftp</module> - <modulesummary>FTP client module (based on the FTP support of the Inets - application).</modulesummary> + <modulesummary>FTP client module (based on the FTP application).</modulesummary> <description> - <p>FTP client module (based on the FTP support of the <c>Inets</c> - application).</p> + <p>FTP client module (based on the <c>ftp</c> application).</p> </description> diff --git a/lib/common_test/src/common_test.app.src b/lib/common_test/src/common_test.app.src index 9becde110b..f686003637 100644 --- a/lib/common_test/src/common_test.app.src +++ b/lib/common_test/src/common_test.app.src @@ -85,6 +85,7 @@ "crypto-3.6", "debugger-4.1", "erts-7.0", + "ftp-1.0.0", "inets-6.0", "kernel-4.0", "observer-2.1", diff --git a/lib/common_test/src/ct_ftp.erl b/lib/common_test/src/ct_ftp.erl index ee4a6a6c45..8b02ae3a0f 100644 --- a/lib/common_test/src/ct_ftp.erl +++ b/lib/common_test/src/ct_ftp.erl @@ -18,7 +18,7 @@ %% %CopyrightEnd% %% -%%% @doc FTP client module (based on the FTP support of the INETS application). +%%% @doc FTP client module (based on the FTP application). %%% %%% @type connection() = handle() | ct:target_name() %%% @type handle() = ct_gen_conn:handle(). Handle for a specific @@ -292,8 +292,8 @@ init(KeyOrName,{IP,Port},{Username,Password}) -> end. ftp_connect(IP,Port,Username,Password) -> - _ = inets:start(), - case inets:start(ftpc,[{host,IP},{port,Port}]) of + _ = ftp:start(), + case ftp:start_service([{host,IP},{port,Port}]) of {ok,FtpPid} -> case ftp:user(FtpPid,Username,Password) of ok -> @@ -341,7 +341,7 @@ reconnect(_Addr,_State) -> terminate(FtpPid,State) -> log(heading(terminate,State#state.target_name), "Closing FTP connection.\nHandle: ~p\n",[FtpPid]), - inets:stop(ftpc,FtpPid). + ftp:stop_service(FtpPid). %%%================================================================= |