4
%% Copyright Ericsson AB 2005-2011. All Rights Reserved.
6
%% The contents of this file are subject to the Erlang Public License,
7
%% Version 1.1, (the "License"); you may not use this file except in
8
%% compliance with the License. You should have received a copy of the
9
%% Erlang Public License along with this software. If not, it can be
10
%% retrieved online at http://www.erlang.org/.
12
%% Software distributed under the License is distributed on an "AS IS"
13
%% basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
14
%% the License for the specific language governing rights and limitations
23
-include_lib("common_test/include/ct.hrl").
24
-include("test_server_line.hrl").
26
%% Test server specific exports
27
-export([all/0, suite/0,groups/0,init_per_group/2,end_per_group/2]).
28
% -export([init_per_testcase/2, end_per_testcase/2]).
29
-export([init_per_suite/1, end_per_suite/1]).
31
-define(FTP_USER, "anonymous").
32
-define(FTP_PASS, passwd()).
33
-define(FTP_PORT, 21).
35
-define(BAD_HOST, "badhostname").
36
-define(BAD_USER, "baduser").
37
-define(BAD_DIR, "baddirectory").
39
-ifdef(ftp_debug_client).
40
-define(ftp_open(Host, Flags), do_ftp_open(Host, [debug] ++ Flags)).
42
-ifdef(ftp_trace_client).
43
-define(ftp_open(Host, Flags), do_ftp_open(Host, [trace] ++ Flags)).
45
-define(ftp_open(Host, Flags), do_ftp_open(Host, [verbose] ++ Flags)).
50
%%--------------------------------------------------------------------
51
%% all(Arg) -> [Doc] | [Case] | {skip, Comment}
55
%% Name of a test case function.
57
%% Description: Returns documentation/test cases in this test suite
58
%% or a skip tuple if the platform is not supported.
59
%%--------------------------------------------------------------------
60
suite() -> [{ct_hooks,[ts_install_cth]}].
63
[{group, solaris8_test}, {group, solaris9_test},
64
{group, solaris10_test}, {group, linux_x86_test},
65
{group, linux_ppc_test}, {group, macosx_x86_test},
66
{group, macosx_ppc_test}, {group, openbsd_test},
67
{group, freebsd_test}, {group, netbsd_test},
68
{group, windows_xp_test},
69
{group, windows_2003_server_test},
70
{group, ticket_tests}].
73
[{solaris8_test, [], [{ftp_solaris8_sparc_test, all}]},
74
{solaris9_test, [], [{ftp_solaris9_sparc_test, all}]},
76
[{ftp_solaris10_sparc_test, all},
77
{ftp_solaris10_x86_test, all}]},
78
{linux_x86_test, [], [{ftp_linux_x86_test, all}]},
79
{linux_ppc_test, [], [{ftp_linux_ppc_test, all}]},
80
{macosx_x86_test, [], [{ftp_macosx_x86_test, all}]},
81
{macosx_ppc_test, [], [{ftp_macosx_ppc_test, all}]},
82
{openbsd_test, [], [{ftp_openbsd_x86_test, all}]},
83
{freebsd_test, [], [{ftp_freebsd_x86_test, all}]},
84
{netbsd_test, [], [{ftp_netbsd_x86_test, all}]},
85
{windows_xp_test, [], [{ftp_windows_xp_test, all}]},
86
{windows_2003_server_test, [],
87
[{ftp_windows_2003_server_test, all}]},
88
{ticket_tests, [], [{ftp_ticket_test, all}]}].
90
init_per_group(_GroupName, Config) ->
93
end_per_group(_GroupName, Config) ->
99
%%--------------------------------------------------------------------
100
%% Function: init_per_suite(Config) -> Config
101
%% Config - [tuple()]
102
%% A list of key/value pairs, holding the test case configuration.
103
%% Description: Initiation before the whole suite
105
%% Note: This function is free to add any key/value pairs to the Config
106
%% variable, but should NOT alter/remove any existing entries.
107
%%--------------------------------------------------------------------
108
init_per_suite(Config) ->
112
%%--------------------------------------------------------------------
113
%% Function: end_per_suite(Config) -> _
114
%% Config - [tuple()]
115
%% A list of key/value pairs, holding the test case configuration.
116
%% Description: Cleanup after the whole suite
117
%%--------------------------------------------------------------------
118
end_per_suite(_Config) ->