~ubuntu-branches/debian/squeeze/erlang/squeeze

« back to all changes in this revision

Viewing changes to lib/inets/test/ftp_windows_xp_test.erl

  • Committer: Bazaar Package Importer
  • Author(s): Sergei Golovan
  • Date: 2010-03-09 17:34:57 UTC
  • mfrom: (10.1.2 sid)
  • Revision ID: james.westby@ubuntu.com-20100309173457-4yd6hlcb2osfhx31
Tags: 1:13.b.4-dfsg-3
Manpages in section 1 are needed even if only arch-dependent packages are
built. So, re-enabled them.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
%%
 
2
%% %CopyrightBegin%
 
3
%% 
 
4
%% Copyright Ericsson AB 2005-2009. All Rights Reserved.
 
5
%% 
 
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/.
 
11
%% 
 
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
 
15
%% under the License.
 
16
%% 
 
17
%% %CopyrightEnd%
 
18
%%
 
19
%%
 
20
 
 
21
-module(ftp_windows_xp_test).
 
22
 
 
23
-compile(export_all).
 
24
 
 
25
-include("test_server.hrl").
 
26
 
 
27
-define(LIB_MOD,ftp_suite_lib).
 
28
-define(CASE_WRAPPER(_A_,_B_,_C_),?LIB_MOD:wrapper(_A_,_B_,_C_)).
 
29
-define(PLATFORM,"Windows xp ").
 
30
 
 
31
%% Test server callback functions
 
32
%%--------------------------------------------------------------------
 
33
%% Function: init_per_suite(Config) -> Config
 
34
%% Config - [tuple()]
 
35
%%   A list of key/value pairs, holding the test case configuration.
 
36
%% Description: Initiation before the whole suite
 
37
%%
 
38
%% Note: This function is free to add any key/value pairs to the Config
 
39
%% variable, but should NOT alter/remove any existing entries.
 
40
%%--------------------------------------------------------------------
 
41
init_per_suite(Config) ->
 
42
    {File, NewFile} = ?LIB_MOD:test_filenames(),
 
43
    NewConfig = [{file, File}, {new_file, NewFile} | Config],
 
44
    ?LIB_MOD:ftpd_init(windows_xp, NewConfig).
 
45
 
 
46
%%--------------------------------------------------------------------
 
47
%% Function: end_per_suite(Config) -> _
 
48
%% Config - [tuple()]
 
49
%%   A list of key/value pairs, holding the test case configuration.
 
50
%% Description: Cleanup after the whole suite
 
51
%%--------------------------------------------------------------------
 
52
end_per_suite(Config) ->
 
53
    ?LIB_MOD:ftpd_fin(Config).
 
54
 
 
55
%%--------------------------------------------------------------------
 
56
%% Function: init_per_testcase(TestCase, Config) -> Config
 
57
%% Case - atom()
 
58
%%   Name of the test case that is about to be run.
 
59
%% Config - [tuple()]
 
60
%%   A list of key/value pairs, holding the test case configuration.
 
61
%%
 
62
%% Description: Initiation before each test case
 
63
%%
 
64
%% Note: This function is free to add any key/value pairs to the Config
 
65
%% variable, but should NOT alter/remove any existing entries.
 
66
%% Description: Initiation before each test case
 
67
%%--------------------------------------------------------------------
 
68
init_per_testcase(Case, Config) ->
 
69
    ftp_suite_lib:init_per_testcase(Case, Config).
 
70
%%--------------------------------------------------------------------
 
71
%% Function: end_per_testcase(TestCase, Config) -> _
 
72
%% Case - atom()
 
73
%%   Name of the test case that is about to be run.
 
74
%% Config - [tuple()]
 
75
%%   A list of key/value pairs, holding the test case configuration.
 
76
%% Description: Cleanup after each test case
 
77
%%--------------------------------------------------------------------
 
78
end_per_testcase(Case, Config) ->
 
79
    ftp_suite_lib:end_per_testcase(Case, Config).
 
80
 
 
81
%%--------------------------------------------------------------------
 
82
%% Function: all(Clause) -> TestCases
 
83
%% Clause - atom() - suite | doc
 
84
%% TestCases - [Case] 
 
85
%% Case - atom()
 
86
%%   Name of a test case.
 
87
%% Description: Returns a list of all test cases in this test suite
 
88
%%--------------------------------------------------------------------
 
89
all(doc) -> 
 
90
    ["Test ftp client"];
 
91
 
 
92
all(suite) -> 
 
93
    [open, open_port, passive, active, api_missuse,
 
94
     not_owner, progress_report].
 
95
 
 
96
open(X) -> ?CASE_WRAPPER(?PLATFORM,X,fun ?LIB_MOD:open/1).
 
97
open_port(X) -> ?CASE_WRAPPER(?PLATFORM,X,fun ?LIB_MOD:open_port/1).
 
98
passive(X) -> ?CASE_WRAPPER(?PLATFORM,X,fun ?LIB_MOD:passive/1).
 
99
active(X) -> ?CASE_WRAPPER(?PLATFORM,X,fun ?LIB_MOD:active/1).
 
100
api_missuse(X) -> ?CASE_WRAPPER(?PLATFORM,X,fun ?LIB_MOD:api_missuse/1).
 
101
not_owner(X) -> ?CASE_WRAPPER(?PLATFORM,X,fun ?LIB_MOD:not_owner/1).
 
102
progress_report(X) -> ?CASE_WRAPPER(?PLATFORM,X,fun ?LIB_MOD:progress_report/1).
 
103
 
 
104
passive_user(X) -> ?LIB_MOD:passive_user(X).
 
105
passive_pwd(X) -> ?LIB_MOD:passive_pwd(X).
 
106
passive_cd(X) -> ?LIB_MOD:passive_cd(X).
 
107
passive_lcd(X) -> ?LIB_MOD:passive_lcd(X).
 
108
passive_ls(X) -> ?LIB_MOD:passive_ls(X).
 
109
passive_nlist(X) -> ?LIB_MOD:passive_nlist(X).
 
110
passive_rename(X) -> ?LIB_MOD:passive_rename(X).
 
111
passive_delete(X) -> ?LIB_MOD:passive_delete(X).
 
112
passive_mkdir(X) -> ?LIB_MOD:passive_mkdir(X).
 
113
passive_send(X) -> ?LIB_MOD:passive_send(X).
 
114
passive_send_bin(X) -> ?LIB_MOD:passive_send_bin(X).
 
115
passive_send_chunk(X) -> ?LIB_MOD:passive_send_chunk(X).
 
116
passive_append(X) -> ?LIB_MOD:passive_append(X).
 
117
passive_append_bin(X) -> ?LIB_MOD:passive_append_bin(X).
 
118
passive_append_chunk(X) -> ?LIB_MOD:passive_append_chunk(X).
 
119
passive_recv(X) -> ?LIB_MOD:passive_recv(X).
 
120
passive_recv_bin(X) -> ?LIB_MOD:passive_recv_bin(X).
 
121
passive_recv_chunk(X) -> ?LIB_MOD:passive_recv_chunk(X).
 
122
passive_type(X) -> ?LIB_MOD:passive_type(X).
 
123
passive_quote(X) -> ?LIB_MOD:passive_quote(X).
 
124
passive_ip_v6_disabled(X) -> ?LIB_MOD:passive_ip_v6_disabled(X).
 
125
active_user(X) -> ?LIB_MOD:active_user(X). 
 
126
active_pwd(X) -> ?LIB_MOD:active_pwd(X). 
 
127
active_cd(X) -> ?LIB_MOD:active_cd(X).
 
128
active_lcd(X) -> ?LIB_MOD:active_lcd(X). 
 
129
active_ls(X) -> ?LIB_MOD:active_ls(X). 
 
130
active_nlist(X) -> ?LIB_MOD:active_nlist(X). 
 
131
active_rename(X) -> ?LIB_MOD:active_rename(X). 
 
132
active_delete(X) -> ?LIB_MOD:active_delete(X). 
 
133
active_mkdir(X) -> ?LIB_MOD:active_mkdir(X). 
 
134
active_send(X) -> ?LIB_MOD:active_send(X). 
 
135
active_send_bin(X) -> ?LIB_MOD:active_send_bin(X). 
 
136
active_send_chunk(X) -> ?LIB_MOD:active_send_chunk(X). 
 
137
active_append(X) -> ?LIB_MOD:active_append(X). 
 
138
active_append_bin(X) -> ?LIB_MOD:active_append_bin(X). 
 
139
active_append_chunk(X) -> ?LIB_MOD:active_append_chunk(X). 
 
140
active_recv(X) -> ?LIB_MOD:active_recv(X). 
 
141
active_recv_bin(X) -> ?LIB_MOD:active_recv_bin(X). 
 
142
active_recv_chunk(X) -> ?LIB_MOD:active_recv_chunk(X). 
 
143
active_type(X) -> ?LIB_MOD:active_type(X). 
 
144
active_quote(X) -> ?LIB_MOD:active_quote(X). 
 
145
active_ip_v6_disabled(X) -> ?LIB_MOD:active_ip_v6_disabled(X).
 
146
progress_report_send(X) -> ?LIB_MOD:progress_report_send(X).
 
147
progress_report_recv(X) -> ?LIB_MOD:progress_report_recv(X).
 
148
 
 
149
fin(Config) ->
 
150
    ?LIB_MOD:ftpd_fin(Config).