diff options
author | Matthias Wachs <wachs@net.in.tum.de> | 2012-04-03 14:53:19 +0000 |
---|---|---|
committer | Matthias Wachs <wachs@net.in.tum.de> | 2012-04-03 14:53:19 +0000 |
commit | 22cde9cd6e66462442647abf271559d9e3bcb41c (patch) | |
tree | ebc9964c2cbecb88db5349d07d3366a42ecf7e28 /src/integration-tests | |
parent | 6fff2c158bad68c4623c6224c59e1bc67cdc17f1 (diff) | |
download | gnunet-22cde9cd6e66462442647abf271559d9e3bcb41c.tar.gz gnunet-22cde9cd6e66462442647abf271559d9e3bcb41c.zip |
- more changes
Diffstat (limited to 'src/integration-tests')
6 files changed, 972 insertions, 3 deletions
diff --git a/src/integration-tests/Makefile.am b/src/integration-tests/Makefile.am index 9d5177b70..93608824d 100644 --- a/src/integration-tests/Makefile.am +++ b/src/integration-tests/Makefile.am | |||
@@ -16,7 +16,9 @@ check_PROGRAMS = | |||
16 | noinst_SCRIPTS = \ | 16 | noinst_SCRIPTS = \ |
17 | gnunet_testing.py \ | 17 | gnunet_testing.py \ |
18 | gnunet_pyexpect.py \ | 18 | gnunet_pyexpect.py \ |
19 | test_integration_connection_values_tcp.py | 19 | test_integration_connection_values_tcp.py \ |
20 | test_integration_connection_values_tcp_udp.py \ | ||
21 | test_integration_connection_values_tcp_udp_http.py | ||
20 | 22 | ||
21 | if HAVE_PYTHON_PEXPECT | 23 | if HAVE_PYTHON_PEXPECT |
22 | check_SCRIPTS = \ | 24 | check_SCRIPTS = \ |
@@ -86,11 +88,20 @@ test_integration_connection_values_tcp.py: test_integration_connection_values_tc | |||
86 | $(do_subst) < $(srcdir)/test_integration_connection_values_tcp.py.in > test_integration_connection_values_tcp.py | 88 | $(do_subst) < $(srcdir)/test_integration_connection_values_tcp.py.in > test_integration_connection_values_tcp.py |
87 | chmod +x test_integration_connection_values_tcp.py | 89 | chmod +x test_integration_connection_values_tcp.py |
88 | 90 | ||
91 | test_integration_connection_values_tcp_udp.py: test_integration_connection_values_tcp_udp.py.in Makefile | ||
92 | $(do_subst) < $(srcdir)/test_integration_connection_values_tcp_udp.py.in > test_integration_connection_values_tcp_udp.py | ||
93 | chmod +x test_integration_connection_values_tcp_udp.py | ||
94 | |||
95 | test_integration_connection_values_tcp_udp_http.py: test_integration_connection_values_tcp_udp_http.py.in Makefile | ||
96 | $(do_subst) < $(srcdir)/test_integration_connection_values_tcp_udp_http.py.in > test_integration_connection_values_tcp_udp_http.py | ||
97 | chmod +x test_integration_connection_values_tcp_udp_http.py | ||
98 | |||
89 | 99 | ||
90 | EXTRA_DIST = \ | 100 | EXTRA_DIST = \ |
91 | gnunet_testing.py.in \ | 101 | gnunet_testing.py.in \ |
92 | gnunet_pyexpect.py.in \ | 102 | gnunet_pyexpect.py.in \ |
93 | test_integration_connection_value.py.in \ | 103 | test_integration_connection_value_tcp.py.in \ |
104 | test_integration_connection_value_tcp_udp.py.in \ | ||
94 | test_integration_bootstrap_and_connect.py.in \ | 105 | test_integration_bootstrap_and_connect.py.in \ |
95 | test_integration_bootstrap_and_connect_and_disconnect.py.in \ | 106 | test_integration_bootstrap_and_connect_and_disconnect.py.in \ |
96 | test_integration_bootstrap_and_connect_and_disconnect_nat.py.in \ | 107 | test_integration_bootstrap_and_connect_and_disconnect_nat.py.in \ |
@@ -103,6 +114,8 @@ EXTRA_DIST = \ | |||
103 | confs/c_no_nat_client_2.conf \ | 114 | confs/c_no_nat_client_2.conf \ |
104 | confs/c_no_nat_client.conf \ | 115 | confs/c_no_nat_client.conf \ |
105 | confs/c_normal_client_tcp.conf \ | 116 | confs/c_normal_client_tcp.conf \ |
117 | confs/c_normal_client_tcp_udp.conf \ | ||
118 | confs/c_normal_client_tcp_udp_http.conf \ | ||
106 | hostkeys/0000-hostkey \ | 119 | hostkeys/0000-hostkey \ |
107 | hostkeys/0001-hostkey \ | 120 | hostkeys/0001-hostkey \ |
108 | hostkeys/0002-hostkey \ | 121 | hostkeys/0002-hostkey \ |
diff --git a/src/integration-tests/confs/c_normal_client_tcp.conf b/src/integration-tests/confs/c_normal_client_tcp.conf index c5de78b79..dd873c4f9 100644 --- a/src/integration-tests/confs/c_normal_client_tcp.conf +++ b/src/integration-tests/confs/c_normal_client_tcp.conf | |||
@@ -1,6 +1,6 @@ | |||
1 | [PATHS] | 1 | [PATHS] |
2 | SERVICEHOME = /tmp/c_normal_client | 2 | SERVICEHOME = /tmp/c_normal_client |
3 | DEFAULTCONFIG = confs/c_normal_client.conf | 3 | DEFAULTCONFIG = confs/c_normal_client_tcp.conf |
4 | 4 | ||
5 | [gnunetd] | 5 | [gnunetd] |
6 | HOSTKEY = hostkeys/0002-hostkey | 6 | HOSTKEY = hostkeys/0002-hostkey |
diff --git a/src/integration-tests/confs/c_normal_client_tcp_udp.conf b/src/integration-tests/confs/c_normal_client_tcp_udp.conf new file mode 100644 index 000000000..b2a42fea5 --- /dev/null +++ b/src/integration-tests/confs/c_normal_client_tcp_udp.conf | |||
@@ -0,0 +1,354 @@ | |||
1 | [PATHS] | ||
2 | SERVICEHOME = /tmp/c_normal_client | ||
3 | DEFAULTCONFIG = confs/c_normal_client_tcp_udp.conf | ||
4 | |||
5 | [gnunetd] | ||
6 | HOSTKEY = hostkeys/0002-hostkey | ||
7 | |||
8 | [client] | ||
9 | HOME = $SERVICEHOME | ||
10 | |||
11 | [vpn] | ||
12 | AUTOSTART = YES | ||
13 | PORT = 0 | ||
14 | HOSTNAME = localhost | ||
15 | HOME = $SERVICEHOME | ||
16 | CONFIG = $DEFAULTCONFIG | ||
17 | BINARY = gnunet-service-dns | ||
18 | ACCEPT_FROM = 127.0.0.1; | ||
19 | ACCEPT_FROM6 = ::1; | ||
20 | UNIXPATH = /tmp/gnunet-service-vpn-57 | ||
21 | |||
22 | |||
23 | [resolver] | ||
24 | AUTOSTART = YES | ||
25 | PORT = 20071 | ||
26 | HOSTNAME = localhost | ||
27 | HOME = $SERVICEHOME | ||
28 | CONFIG = $DEFAULTCONFIG | ||
29 | BINARY = gnunet-service-resolver | ||
30 | ACCEPT_FROM = 127.0.0.1; | ||
31 | ACCEPT_FROM6 = ::1; | ||
32 | UNIXPATH = /tmp/test-service-resolver-56 | ||
33 | UNIX_MATCH_UID = NO | ||
34 | UNIX_MATCH_GID = NO | ||
35 | |||
36 | [mesh] | ||
37 | AUTOSTART = YES | ||
38 | PORT = 20070 | ||
39 | HOSTNAME = localhost | ||
40 | HOME = $SERVICEHOME | ||
41 | CONFIG = $DEFAULTCONFIG | ||
42 | BINARY = gnunet-service-mesh | ||
43 | ACCEPT_FROM = 127.0.0.1; | ||
44 | ACCEPT_FROM6 = ::1; | ||
45 | UNIXPATH = /tmp/test-service-mesh-55 | ||
46 | UNIX_MATCH_UID = YES | ||
47 | UNIX_MATCH_GID = YES | ||
48 | |||
49 | [nse] | ||
50 | AUTOSTART = YES | ||
51 | PORT = 20069 | ||
52 | HOSTNAME = localhost | ||
53 | HOME = $SERVICEHOME | ||
54 | CONFIG = $DEFAULTCONFIG | ||
55 | BINARY = gnunet-service-nse | ||
56 | ACCEPT_FROM = 127.0.0.1; | ||
57 | ACCEPT_FROM6 = ::1; | ||
58 | UNIXPATH = /tmp/test-service-nse-54 | ||
59 | UNIX_MATCH_UID = YES | ||
60 | UNIX_MATCH_GID = YES | ||
61 | PROOFFILE = $SERVICEHOME/.nse-proof | ||
62 | HISTOGRAM = $SERVICEHOME/nse-history.log | ||
63 | WORKDELAY = 5 ms | ||
64 | INTERVAL = 1 h | ||
65 | WORKBITS = 26 | ||
66 | |||
67 | [topology] | ||
68 | MINIMUM-FRIENDS = 0 | ||
69 | FRIENDS-ONLY = NO | ||
70 | AUTOCONNECT = YES | ||
71 | TARGET-CONNECTION-COUNT = 16 | ||
72 | FRIENDS = $SERVICEHOME/friends | ||
73 | CONFIG = $DEFAULTCONFIG | ||
74 | BINARY = gnunet-daemon-topology | ||
75 | |||
76 | [datastore] | ||
77 | AUTOSTART = YES | ||
78 | UNIXPATH = /tmp/test-service-datastore-53 | ||
79 | UNIX_MATCH_UID = YES | ||
80 | UNIX_MATCH_GID = YES | ||
81 | PORT = 20068 | ||
82 | HOSTNAME = localhost | ||
83 | HOME = $SERVICEHOME | ||
84 | CONFIG = $DEFAULTCONFIG | ||
85 | BINARY = gnunet-service-datastore | ||
86 | ACCEPT_FROM = 127.0.0.1; | ||
87 | ACCEPT_FROM6 = ::1; | ||
88 | QUOTA = 100 MB | ||
89 | BLOOMFILTER = $SERVICEHOME/fs/bloomfilter | ||
90 | DATABASE = sqlite | ||
91 | |||
92 | [datastore-sqlite] | ||
93 | FILENAME = $SERVICEHOME/datastore/sqlite.db | ||
94 | |||
95 | [datastore-postgres] | ||
96 | CONFIG = connect_timeout=10; dbname=gnunet | ||
97 | |||
98 | [datastore-mysql] | ||
99 | DATABASE = gnunet | ||
100 | CONFIG = ~/.my.cnf | ||
101 | |||
102 | [peerinfo] | ||
103 | AUTOSTART = YES | ||
104 | PORT = 20067 | ||
105 | HOSTNAME = localhost | ||
106 | HOME = $SERVICEHOME | ||
107 | CONFIG = $DEFAULTCONFIG | ||
108 | BINARY = gnunet-service-peerinfo | ||
109 | ACCEPT_FROM = 127.0.0.1; | ||
110 | ACCEPT_FROM6 = ::1; | ||
111 | UNIXPATH = /tmp/test-service-peerinfo-52 | ||
112 | UNIX_MATCH_UID = NO | ||
113 | UNIX_MATCH_GID = YES | ||
114 | HOSTS = $SERVICEHOME/data/hosts/ | ||
115 | |||
116 | [TESTING] | ||
117 | WEAKRANDOM = NO | ||
118 | CONNECT_TIMEOUT = 30 s | ||
119 | CONNECT_ATTEMPTS = 3 | ||
120 | MAX_OUTSTANDING_CONNECTIONS = 50 | ||
121 | DELETE_FILES = YES | ||
122 | |||
123 | [ats] | ||
124 | AUTOSTART = YES | ||
125 | PORT = 20066 | ||
126 | HOSTNAME = localhost | ||
127 | HOME = $SERVICEHOME | ||
128 | CONFIG = $DEFAULTCONFIG | ||
129 | BINARY = gnunet-service-ats | ||
130 | ACCEPT_FROM = 127.0.0.1; | ||
131 | ACCEPT_FROM6 = ::1; | ||
132 | UNIXPATH = /tmp/test-service-ats-51 | ||
133 | UNIX_MATCH_UID = YES | ||
134 | UNIX_MATCH_GID = YES | ||
135 | WAN_QUOTA_IN = 65536 | ||
136 | WAN_QUOTA_OUT = 65536 | ||
137 | DUMP_MLP = NO | ||
138 | DUMP_SOLUTION = NO | ||
139 | DUMP_OVERWRITE = NO | ||
140 | DUMP_MIN_PEERS = 0 | ||
141 | DUMP_MIN_ADDRS = 0 | ||
142 | ATS_MIN_INTERVAL = 15000 | ||
143 | ATS_EXEC_INTERVAL = 30000 | ||
144 | |||
145 | [transport] | ||
146 | AUTOSTART = YES | ||
147 | PORT = 20065 | ||
148 | HOSTNAME = localhost | ||
149 | HOME = $SERVICEHOME | ||
150 | CONFIG = $DEFAULTCONFIG | ||
151 | BINARY = gnunet-service-transport | ||
152 | NEIGHBOUR_LIMIT = 50 | ||
153 | ACCEPT_FROM = 127.0.0.1; | ||
154 | ACCEPT_FROM6 = ::1; | ||
155 | PLUGINS = tcp udp | ||
156 | UNIXPATH = /tmp/test-service-transport-50 | ||
157 | BLACKLIST_FILE = $SERVICEHOME/blacklist | ||
158 | UNIX_MATCH_UID = YES | ||
159 | UNIX_MATCH_GID = YES | ||
160 | |||
161 | [transport-tcp] | ||
162 | PORT = 0 | ||
163 | ADVERTISED_PORT = 20064 | ||
164 | MAX_CONNECTIONS = 128 | ||
165 | TIMEOUT = 5 s | ||
166 | USE_LOCALADDR = YES | ||
167 | |||
168 | [transport-udp] | ||
169 | PORT = 0 | ||
170 | BROADCAST = YES | ||
171 | BROADCAST_INTERVAL = 30000 | ||
172 | MAX_BPS = 1000000 | ||
173 | USE_LOCALADDR = YES | ||
174 | |||
175 | [transport-http] | ||
176 | PORT = 0 | ||
177 | MAX_CONNECTIONS = 128 | ||
178 | |||
179 | [transport-https] | ||
180 | PORT = 0 | ||
181 | CRYPTO_INIT = NORMAL | ||
182 | KEY_FILE = https.key | ||
183 | CERT_FILE = https.cert | ||
184 | MAX_CONNECTIONS = 128 | ||
185 | |||
186 | [transport-wlan] | ||
187 | INTERFACE = mon0 | ||
188 | TESTMODE = 0 | ||
189 | |||
190 | [datacache-mysql] | ||
191 | DATABASE = gnunet | ||
192 | CONFIG = ~/.my.cnf | ||
193 | |||
194 | [datacache-postgres] | ||
195 | CONFIG = connect_timeout=10; dbname=gnunet | ||
196 | |||
197 | [template] | ||
198 | AUTOSTART = NO | ||
199 | PORT = 20060 | ||
200 | HOSTNAME = localhost | ||
201 | HOME = $SERVICEHOME | ||
202 | CONFIG = $DEFAULTCONFIG | ||
203 | BINARY = gnunet-service-template | ||
204 | ACCEPT_FROM = 127.0.0.1; | ||
205 | ACCEPT_FROM6 = ::1; | ||
206 | UNIXPATH = /tmp/test-service-template-49 | ||
207 | UNIX_MATCH_UID = YES | ||
208 | UNIX_MATCH_GID = YES | ||
209 | |||
210 | [fs] | ||
211 | AUTOSTART = YES | ||
212 | INDEXDB = $SERVICEHOME/idxinfo.lst | ||
213 | TRUST = $SERVICEHOME/data/credit/ | ||
214 | IDENTITY_DIR = $SERVICEHOME/identities/ | ||
215 | STATE_DIR = $SERVICEHOME/persistence/ | ||
216 | UPDATE_DIR = $SERVICEHOME/updates/ | ||
217 | PORT = 20059 | ||
218 | HOSTNAME = localhost | ||
219 | HOME = $SERVICEHOME | ||
220 | CONFIG = $DEFAULTCONFIG | ||
221 | BINARY = gnunet-service-fs | ||
222 | ACCEPT_FROM = 127.0.0.1; | ||
223 | ACCEPT_FROM6 = ::1; | ||
224 | DELAY = YES | ||
225 | CONTENT_CACHING = YES | ||
226 | CONTENT_PUSHING = YES | ||
227 | UNIXPATH = /tmp/test-service-fs-48 | ||
228 | UNIX_MATCH_UID = NO | ||
229 | UNIX_MATCH_GID = YES | ||
230 | MAX_PENDING_REQUESTS = 65536 | ||
231 | MIN_MIGRATION_DELAY = 100 ms | ||
232 | EXPECTED_NEIGHBOUR_COUNT = 128 | ||
233 | |||
234 | [vpn] | ||
235 | CONFIG = $DEFAULTCONFIG | ||
236 | BINARY = gnunet-daemon-vpn | ||
237 | IPV6ADDR = 1234::1 | ||
238 | IPV6PREFIX = 32 | ||
239 | IPV4ADDR = 10.11.10.1 | ||
240 | IPV4MASK = 255.255.0.0 | ||
241 | VIRTDNS = 10.11.10.2 | ||
242 | VIRTDNS6 = 1234::17 | ||
243 | IFNAME = vpn-gnunet | ||
244 | |||
245 | [exit] | ||
246 | CONFIG = $DEFAULTCONFIG | ||
247 | BINARY = gnunet-daemon-exit | ||
248 | IPV6ADDR = 1234:1::1 | ||
249 | IPV6PREFIX = 32 | ||
250 | IPV4ADDR = 10.10.1.1 | ||
251 | IPV4MASK = 255.255.0.0 | ||
252 | IFNAME = exit-gnunet | ||
253 | ENABLE_UDP = NO | ||
254 | ENABLE_TCP = NO | ||
255 | |||
256 | [dns] | ||
257 | AUTOSTART = YES | ||
258 | PORT = 0 | ||
259 | HOSTNAME = localhost | ||
260 | HOME = $SERVICEHOME | ||
261 | CONFIG = $DEFAULTCONFIG | ||
262 | BINARY = gnunet-service-dns | ||
263 | ACCEPT_FROM = 127.0.0.1; | ||
264 | ACCEPT_FROM6 = ::1; | ||
265 | UNIXPATH = /tmp/test-service-dns-47 | ||
266 | PROVIDE_EXIT = NO | ||
267 | |||
268 | [arm] | ||
269 | PORT = 20058 | ||
270 | HOSTNAME = localhost | ||
271 | HOME = $SERVICEHOME | ||
272 | CONFIG = $DEFAULTCONFIG | ||
273 | BINARY = gnunet-service-arm | ||
274 | ACCEPT_FROM = 127.0.0.1; | ||
275 | ACCEPT_FROM6 = ::1; | ||
276 | DEFAULTSERVICES = topology hostlist fs | ||
277 | UNIXPATH = /tmp/test-service-arm-46 | ||
278 | UNIX_MATCH_UID = YES | ||
279 | UNIX_MATCH_GID = YES | ||
280 | |||
281 | [hostlist] | ||
282 | HTTPPORT = 8080 | ||
283 | HOME = $SERVICEHOME | ||
284 | HOSTLISTFILE = $SERVICEHOME/hostlist/learned.data | ||
285 | CONFIG = $DEFAULTCONFIG | ||
286 | BINARY = gnunet-daemon-hostlist | ||
287 | OPTIONS = -b | ||
288 | SERVERS = http://v9.gnunet.org/hostlist http://ioerror.gnunet.org:65535/ | ||
289 | HTTP-PROXY = | ||
290 | |||
291 | [core] | ||
292 | AUTOSTART = YES | ||
293 | PORT = 20057 | ||
294 | HOSTNAME = localhost | ||
295 | HOME = $SERVICEHOME | ||
296 | CONFIG = $DEFAULTCONFIG | ||
297 | BINARY = gnunet-service-core | ||
298 | ACCEPT_FROM = 127.0.0.1; | ||
299 | ACCEPT_FROM6 = ::1; | ||
300 | UNIXPATH = /tmp/test-service-core-45 | ||
301 | UNIX_MATCH_UID = YES | ||
302 | UNIX_MATCH_GID = YES | ||
303 | |||
304 | [nat] | ||
305 | BEHIND_NAT = YES | ||
306 | PUNCHED_NAT = NO | ||
307 | ENABLE_UPNP = NO | ||
308 | USE_LOCALADDR = YES | ||
309 | USE_HOSTNAME = NO | ||
310 | ENABLE_ICMP_CLIENT = NO | ||
311 | ENABLE_ICMP_SERVER = NO | ||
312 | DISABLEV6 = YES | ||
313 | RETURN_LOCAL_ADDRESSES = NO | ||
314 | HOSTNAME_DNS_FREQUENCY = 1200000 | ||
315 | IFC_SCAN_FREQUENCY = 3000000 | ||
316 | DYNDNS_FREQUENCY = 140000 | ||
317 | EXTERNAL_ADDRESS = 127.0.0.1 | ||
318 | INTERNAL_ADDRESS = 127.0.0.1 | ||
319 | BINDTO = 127.0.0.1 | ||
320 | |||
321 | [gnunet-nat-server] | ||
322 | HOSTNAME = gnunet.org | ||
323 | PORT = 20056 | ||
324 | |||
325 | [statistics] | ||
326 | AUTOSTART = YES | ||
327 | PORT = 20055 | ||
328 | HOSTNAME = localhost | ||
329 | HOME = $SERVICEHOME | ||
330 | CONFIG = $DEFAULTCONFIG | ||
331 | BINARY = gnunet-service-statistics | ||
332 | ACCEPT_FROM = 127.0.0.1; | ||
333 | ACCEPT_FROM6 = ::1; | ||
334 | UNIXPATH = /tmp/test-service-statistics-44 | ||
335 | UNIX_MATCH_UID = NO | ||
336 | UNIX_MATCH_GID = YES | ||
337 | |||
338 | [dht] | ||
339 | AUTOSTART = YES | ||
340 | PORT = 20054 | ||
341 | HOSTNAME = localhost | ||
342 | HOME = $SERVICEHOME | ||
343 | CONFIG = $DEFAULTCONFIG | ||
344 | BINARY = gnunet-service-dht | ||
345 | ACCEPT_FROM = 127.0.0.1; | ||
346 | ACCEPT_FROM6 = ::1; | ||
347 | BUCKET_SIZE = 4 | ||
348 | UNIXPATH = /tmp/test-service-dht-43 | ||
349 | UNIX_MATCH_UID = YES | ||
350 | UNIX_MATCH_GID = YES | ||
351 | |||
352 | [dhtcache] | ||
353 | DATABASE = sqlite | ||
354 | QUOTA = 1 MB \ No newline at end of file | ||
diff --git a/src/integration-tests/confs/c_normal_client_tcp_udp_http.conf b/src/integration-tests/confs/c_normal_client_tcp_udp_http.conf new file mode 100644 index 000000000..453be3e38 --- /dev/null +++ b/src/integration-tests/confs/c_normal_client_tcp_udp_http.conf | |||
@@ -0,0 +1,354 @@ | |||
1 | [PATHS] | ||
2 | SERVICEHOME = /tmp/c_normal_client | ||
3 | DEFAULTCONFIG = confs/c_normal_client_tcp_udp_http.conf | ||
4 | |||
5 | [gnunetd] | ||
6 | HOSTKEY = hostkeys/0002-hostkey | ||
7 | |||
8 | [client] | ||
9 | HOME = $SERVICEHOME | ||
10 | |||
11 | [vpn] | ||
12 | AUTOSTART = YES | ||
13 | PORT = 0 | ||
14 | HOSTNAME = localhost | ||
15 | HOME = $SERVICEHOME | ||
16 | CONFIG = $DEFAULTCONFIG | ||
17 | BINARY = gnunet-service-dns | ||
18 | ACCEPT_FROM = 127.0.0.1; | ||
19 | ACCEPT_FROM6 = ::1; | ||
20 | UNIXPATH = /tmp/gnunet-service-vpn-57 | ||
21 | |||
22 | |||
23 | [resolver] | ||
24 | AUTOSTART = YES | ||
25 | PORT = 20071 | ||
26 | HOSTNAME = localhost | ||
27 | HOME = $SERVICEHOME | ||
28 | CONFIG = $DEFAULTCONFIG | ||
29 | BINARY = gnunet-service-resolver | ||
30 | ACCEPT_FROM = 127.0.0.1; | ||
31 | ACCEPT_FROM6 = ::1; | ||
32 | UNIXPATH = /tmp/test-service-resolver-56 | ||
33 | UNIX_MATCH_UID = NO | ||
34 | UNIX_MATCH_GID = NO | ||
35 | |||
36 | [mesh] | ||
37 | AUTOSTART = YES | ||
38 | PORT = 20070 | ||
39 | HOSTNAME = localhost | ||
40 | HOME = $SERVICEHOME | ||
41 | CONFIG = $DEFAULTCONFIG | ||
42 | BINARY = gnunet-service-mesh | ||
43 | ACCEPT_FROM = 127.0.0.1; | ||
44 | ACCEPT_FROM6 = ::1; | ||
45 | UNIXPATH = /tmp/test-service-mesh-55 | ||
46 | UNIX_MATCH_UID = YES | ||
47 | UNIX_MATCH_GID = YES | ||
48 | |||
49 | [nse] | ||
50 | AUTOSTART = YES | ||
51 | PORT = 20069 | ||
52 | HOSTNAME = localhost | ||
53 | HOME = $SERVICEHOME | ||
54 | CONFIG = $DEFAULTCONFIG | ||
55 | BINARY = gnunet-service-nse | ||
56 | ACCEPT_FROM = 127.0.0.1; | ||
57 | ACCEPT_FROM6 = ::1; | ||
58 | UNIXPATH = /tmp/test-service-nse-54 | ||
59 | UNIX_MATCH_UID = YES | ||
60 | UNIX_MATCH_GID = YES | ||
61 | PROOFFILE = $SERVICEHOME/.nse-proof | ||
62 | HISTOGRAM = $SERVICEHOME/nse-history.log | ||
63 | WORKDELAY = 5 ms | ||
64 | INTERVAL = 1 h | ||
65 | WORKBITS = 26 | ||
66 | |||
67 | [topology] | ||
68 | MINIMUM-FRIENDS = 0 | ||
69 | FRIENDS-ONLY = NO | ||
70 | AUTOCONNECT = YES | ||
71 | TARGET-CONNECTION-COUNT = 16 | ||
72 | FRIENDS = $SERVICEHOME/friends | ||
73 | CONFIG = $DEFAULTCONFIG | ||
74 | BINARY = gnunet-daemon-topology | ||
75 | |||
76 | [datastore] | ||
77 | AUTOSTART = YES | ||
78 | UNIXPATH = /tmp/test-service-datastore-53 | ||
79 | UNIX_MATCH_UID = YES | ||
80 | UNIX_MATCH_GID = YES | ||
81 | PORT = 20068 | ||
82 | HOSTNAME = localhost | ||
83 | HOME = $SERVICEHOME | ||
84 | CONFIG = $DEFAULTCONFIG | ||
85 | BINARY = gnunet-service-datastore | ||
86 | ACCEPT_FROM = 127.0.0.1; | ||
87 | ACCEPT_FROM6 = ::1; | ||
88 | QUOTA = 100 MB | ||
89 | BLOOMFILTER = $SERVICEHOME/fs/bloomfilter | ||
90 | DATABASE = sqlite | ||
91 | |||
92 | [datastore-sqlite] | ||
93 | FILENAME = $SERVICEHOME/datastore/sqlite.db | ||
94 | |||
95 | [datastore-postgres] | ||
96 | CONFIG = connect_timeout=10; dbname=gnunet | ||
97 | |||
98 | [datastore-mysql] | ||
99 | DATABASE = gnunet | ||
100 | CONFIG = ~/.my.cnf | ||
101 | |||
102 | [peerinfo] | ||
103 | AUTOSTART = YES | ||
104 | PORT = 20067 | ||
105 | HOSTNAME = localhost | ||
106 | HOME = $SERVICEHOME | ||
107 | CONFIG = $DEFAULTCONFIG | ||
108 | BINARY = gnunet-service-peerinfo | ||
109 | ACCEPT_FROM = 127.0.0.1; | ||
110 | ACCEPT_FROM6 = ::1; | ||
111 | UNIXPATH = /tmp/test-service-peerinfo-52 | ||
112 | UNIX_MATCH_UID = NO | ||
113 | UNIX_MATCH_GID = YES | ||
114 | HOSTS = $SERVICEHOME/data/hosts/ | ||
115 | |||
116 | [TESTING] | ||
117 | WEAKRANDOM = NO | ||
118 | CONNECT_TIMEOUT = 30 s | ||
119 | CONNECT_ATTEMPTS = 3 | ||
120 | MAX_OUTSTANDING_CONNECTIONS = 50 | ||
121 | DELETE_FILES = YES | ||
122 | |||
123 | [ats] | ||
124 | AUTOSTART = YES | ||
125 | PORT = 20066 | ||
126 | HOSTNAME = localhost | ||
127 | HOME = $SERVICEHOME | ||
128 | CONFIG = $DEFAULTCONFIG | ||
129 | BINARY = gnunet-service-ats | ||
130 | ACCEPT_FROM = 127.0.0.1; | ||
131 | ACCEPT_FROM6 = ::1; | ||
132 | UNIXPATH = /tmp/test-service-ats-51 | ||
133 | UNIX_MATCH_UID = YES | ||
134 | UNIX_MATCH_GID = YES | ||
135 | WAN_QUOTA_IN = 65536 | ||
136 | WAN_QUOTA_OUT = 65536 | ||
137 | DUMP_MLP = NO | ||
138 | DUMP_SOLUTION = NO | ||
139 | DUMP_OVERWRITE = NO | ||
140 | DUMP_MIN_PEERS = 0 | ||
141 | DUMP_MIN_ADDRS = 0 | ||
142 | ATS_MIN_INTERVAL = 15000 | ||
143 | ATS_EXEC_INTERVAL = 30000 | ||
144 | |||
145 | [transport] | ||
146 | AUTOSTART = YES | ||
147 | PORT = 20065 | ||
148 | HOSTNAME = localhost | ||
149 | HOME = $SERVICEHOME | ||
150 | CONFIG = $DEFAULTCONFIG | ||
151 | BINARY = gnunet-service-transport | ||
152 | NEIGHBOUR_LIMIT = 50 | ||
153 | ACCEPT_FROM = 127.0.0.1; | ||
154 | ACCEPT_FROM6 = ::1; | ||
155 | PLUGINS = tcp udp http | ||
156 | UNIXPATH = /tmp/test-service-transport-50 | ||
157 | BLACKLIST_FILE = $SERVICEHOME/blacklist | ||
158 | UNIX_MATCH_UID = YES | ||
159 | UNIX_MATCH_GID = YES | ||
160 | |||
161 | [transport-tcp] | ||
162 | PORT = 0 | ||
163 | ADVERTISED_PORT = 20064 | ||
164 | MAX_CONNECTIONS = 128 | ||
165 | TIMEOUT = 5 s | ||
166 | USE_LOCALADDR = YES | ||
167 | |||
168 | [transport-udp] | ||
169 | PORT = 0 | ||
170 | BROADCAST = YES | ||
171 | BROADCAST_INTERVAL = 30000 | ||
172 | MAX_BPS = 1000000 | ||
173 | USE_LOCALADDR = YES | ||
174 | |||
175 | [transport-http] | ||
176 | PORT = 0 | ||
177 | MAX_CONNECTIONS = 128 | ||
178 | |||
179 | [transport-https] | ||
180 | PORT = 0 | ||
181 | CRYPTO_INIT = NORMAL | ||
182 | KEY_FILE = https.key | ||
183 | CERT_FILE = https.cert | ||
184 | MAX_CONNECTIONS = 128 | ||
185 | |||
186 | [transport-wlan] | ||
187 | INTERFACE = mon0 | ||
188 | TESTMODE = 0 | ||
189 | |||
190 | [datacache-mysql] | ||
191 | DATABASE = gnunet | ||
192 | CONFIG = ~/.my.cnf | ||
193 | |||
194 | [datacache-postgres] | ||
195 | CONFIG = connect_timeout=10; dbname=gnunet | ||
196 | |||
197 | [template] | ||
198 | AUTOSTART = NO | ||
199 | PORT = 20060 | ||
200 | HOSTNAME = localhost | ||
201 | HOME = $SERVICEHOME | ||
202 | CONFIG = $DEFAULTCONFIG | ||
203 | BINARY = gnunet-service-template | ||
204 | ACCEPT_FROM = 127.0.0.1; | ||
205 | ACCEPT_FROM6 = ::1; | ||
206 | UNIXPATH = /tmp/test-service-template-49 | ||
207 | UNIX_MATCH_UID = YES | ||
208 | UNIX_MATCH_GID = YES | ||
209 | |||
210 | [fs] | ||
211 | AUTOSTART = YES | ||
212 | INDEXDB = $SERVICEHOME/idxinfo.lst | ||
213 | TRUST = $SERVICEHOME/data/credit/ | ||
214 | IDENTITY_DIR = $SERVICEHOME/identities/ | ||
215 | STATE_DIR = $SERVICEHOME/persistence/ | ||
216 | UPDATE_DIR = $SERVICEHOME/updates/ | ||
217 | PORT = 20059 | ||
218 | HOSTNAME = localhost | ||
219 | HOME = $SERVICEHOME | ||
220 | CONFIG = $DEFAULTCONFIG | ||
221 | BINARY = gnunet-service-fs | ||
222 | ACCEPT_FROM = 127.0.0.1; | ||
223 | ACCEPT_FROM6 = ::1; | ||
224 | DELAY = YES | ||
225 | CONTENT_CACHING = YES | ||
226 | CONTENT_PUSHING = YES | ||
227 | UNIXPATH = /tmp/test-service-fs-48 | ||
228 | UNIX_MATCH_UID = NO | ||
229 | UNIX_MATCH_GID = YES | ||
230 | MAX_PENDING_REQUESTS = 65536 | ||
231 | MIN_MIGRATION_DELAY = 100 ms | ||
232 | EXPECTED_NEIGHBOUR_COUNT = 128 | ||
233 | |||
234 | [vpn] | ||
235 | CONFIG = $DEFAULTCONFIG | ||
236 | BINARY = gnunet-daemon-vpn | ||
237 | IPV6ADDR = 1234::1 | ||
238 | IPV6PREFIX = 32 | ||
239 | IPV4ADDR = 10.11.10.1 | ||
240 | IPV4MASK = 255.255.0.0 | ||
241 | VIRTDNS = 10.11.10.2 | ||
242 | VIRTDNS6 = 1234::17 | ||
243 | IFNAME = vpn-gnunet | ||
244 | |||
245 | [exit] | ||
246 | CONFIG = $DEFAULTCONFIG | ||
247 | BINARY = gnunet-daemon-exit | ||
248 | IPV6ADDR = 1234:1::1 | ||
249 | IPV6PREFIX = 32 | ||
250 | IPV4ADDR = 10.10.1.1 | ||
251 | IPV4MASK = 255.255.0.0 | ||
252 | IFNAME = exit-gnunet | ||
253 | ENABLE_UDP = NO | ||
254 | ENABLE_TCP = NO | ||
255 | |||
256 | [dns] | ||
257 | AUTOSTART = YES | ||
258 | PORT = 0 | ||
259 | HOSTNAME = localhost | ||
260 | HOME = $SERVICEHOME | ||
261 | CONFIG = $DEFAULTCONFIG | ||
262 | BINARY = gnunet-service-dns | ||
263 | ACCEPT_FROM = 127.0.0.1; | ||
264 | ACCEPT_FROM6 = ::1; | ||
265 | UNIXPATH = /tmp/test-service-dns-47 | ||
266 | PROVIDE_EXIT = NO | ||
267 | |||
268 | [arm] | ||
269 | PORT = 20058 | ||
270 | HOSTNAME = localhost | ||
271 | HOME = $SERVICEHOME | ||
272 | CONFIG = $DEFAULTCONFIG | ||
273 | BINARY = gnunet-service-arm | ||
274 | ACCEPT_FROM = 127.0.0.1; | ||
275 | ACCEPT_FROM6 = ::1; | ||
276 | DEFAULTSERVICES = topology hostlist fs | ||
277 | UNIXPATH = /tmp/test-service-arm-46 | ||
278 | UNIX_MATCH_UID = YES | ||
279 | UNIX_MATCH_GID = YES | ||
280 | |||
281 | [hostlist] | ||
282 | HTTPPORT = 8080 | ||
283 | HOME = $SERVICEHOME | ||
284 | HOSTLISTFILE = $SERVICEHOME/hostlist/learned.data | ||
285 | CONFIG = $DEFAULTCONFIG | ||
286 | BINARY = gnunet-daemon-hostlist | ||
287 | OPTIONS = -b | ||
288 | SERVERS = http://v9.gnunet.org/hostlist http://ioerror.gnunet.org:65535/ | ||
289 | HTTP-PROXY = | ||
290 | |||
291 | [core] | ||
292 | AUTOSTART = YES | ||
293 | PORT = 20057 | ||
294 | HOSTNAME = localhost | ||
295 | HOME = $SERVICEHOME | ||
296 | CONFIG = $DEFAULTCONFIG | ||
297 | BINARY = gnunet-service-core | ||
298 | ACCEPT_FROM = 127.0.0.1; | ||
299 | ACCEPT_FROM6 = ::1; | ||
300 | UNIXPATH = /tmp/test-service-core-45 | ||
301 | UNIX_MATCH_UID = YES | ||
302 | UNIX_MATCH_GID = YES | ||
303 | |||
304 | [nat] | ||
305 | BEHIND_NAT = YES | ||
306 | PUNCHED_NAT = NO | ||
307 | ENABLE_UPNP = NO | ||
308 | USE_LOCALADDR = YES | ||
309 | USE_HOSTNAME = NO | ||
310 | ENABLE_ICMP_CLIENT = NO | ||
311 | ENABLE_ICMP_SERVER = NO | ||
312 | DISABLEV6 = YES | ||
313 | RETURN_LOCAL_ADDRESSES = NO | ||
314 | HOSTNAME_DNS_FREQUENCY = 1200000 | ||
315 | IFC_SCAN_FREQUENCY = 3000000 | ||
316 | DYNDNS_FREQUENCY = 140000 | ||
317 | EXTERNAL_ADDRESS = 127.0.0.1 | ||
318 | INTERNAL_ADDRESS = 127.0.0.1 | ||
319 | BINDTO = 127.0.0.1 | ||
320 | |||
321 | [gnunet-nat-server] | ||
322 | HOSTNAME = gnunet.org | ||
323 | PORT = 20056 | ||
324 | |||
325 | [statistics] | ||
326 | AUTOSTART = YES | ||
327 | PORT = 20055 | ||
328 | HOSTNAME = localhost | ||
329 | HOME = $SERVICEHOME | ||
330 | CONFIG = $DEFAULTCONFIG | ||
331 | BINARY = gnunet-service-statistics | ||
332 | ACCEPT_FROM = 127.0.0.1; | ||
333 | ACCEPT_FROM6 = ::1; | ||
334 | UNIXPATH = /tmp/test-service-statistics-44 | ||
335 | UNIX_MATCH_UID = NO | ||
336 | UNIX_MATCH_GID = YES | ||
337 | |||
338 | [dht] | ||
339 | AUTOSTART = YES | ||
340 | PORT = 20054 | ||
341 | HOSTNAME = localhost | ||
342 | HOME = $SERVICEHOME | ||
343 | CONFIG = $DEFAULTCONFIG | ||
344 | BINARY = gnunet-service-dht | ||
345 | ACCEPT_FROM = 127.0.0.1; | ||
346 | ACCEPT_FROM6 = ::1; | ||
347 | BUCKET_SIZE = 4 | ||
348 | UNIXPATH = /tmp/test-service-dht-43 | ||
349 | UNIX_MATCH_UID = YES | ||
350 | UNIX_MATCH_GID = YES | ||
351 | |||
352 | [dhtcache] | ||
353 | DATABASE = sqlite | ||
354 | QUOTA = 1 MB \ No newline at end of file | ||
diff --git a/src/integration-tests/test_integration_connection_values_tcp_udp.py.in b/src/integration-tests/test_integration_connection_values_tcp_udp.py.in new file mode 100755 index 000000000..905ea9b1b --- /dev/null +++ b/src/integration-tests/test_integration_connection_values_tcp_udp.py.in | |||
@@ -0,0 +1,124 @@ | |||
1 | #!/usr/bin/python | ||
2 | # This file is part of GNUnet. | ||
3 | # (C) 2010 Christian Grothoff (and other contributing authors) | ||
4 | # | ||
5 | # GNUnet is free software; you can redistribute it and/or modify | ||
6 | # it under the terms of the GNU General Public License as published | ||
7 | # by the Free Software Foundation; either version 2, or (at your | ||
8 | # option) any later version. | ||
9 | # | ||
10 | # GNUnet is distributed in the hope that it will be useful, but | ||
11 | # WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
13 | # General Public License for more details. | ||
14 | # | ||
15 | # You should have received a copy of the GNU General Public License | ||
16 | # along with GNUnet; see the file COPYING. If not, write to the | ||
17 | # Free Software Foundation, Inc., 59 Temple Place - Suite 330, | ||
18 | # Boston, MA 02111-1307, USA. | ||
19 | # | ||
20 | # | ||
21 | # | ||
22 | # This test starts 3 peers and expects bootstrap and a connected clique | ||
23 | # | ||
24 | # Conditions for successful exit: | ||
25 | # Both peers have 1 connected peer in transport, core, topology, fs | ||
26 | |||
27 | import sys | ||
28 | import os | ||
29 | import subprocess | ||
30 | import re | ||
31 | import shutil | ||
32 | import time | ||
33 | import pexpect | ||
34 | from gnunet_testing import Peer | ||
35 | from gnunet_testing import Test | ||
36 | from gnunet_testing import Check | ||
37 | from gnunet_testing import Condition | ||
38 | from gnunet_testing import * | ||
39 | |||
40 | |||
41 | #definitions | ||
42 | |||
43 | testname = "test_integration_connection_value" | ||
44 | verbose = True | ||
45 | check_timeout = 30 | ||
46 | |||
47 | |||
48 | def cleanup (): | ||
49 | if os.name == "nt": | ||
50 | shutil.rmtree (os.path.join (os.getenv ("TEMP"), "c_normal_client"), True) | ||
51 | else: | ||
52 | shutil.rmtree ("/tmp/c_normal_client/", True) | ||
53 | |||
54 | |||
55 | def success_cont (check): | ||
56 | global success | ||
57 | success = True; | ||
58 | |||
59 | def fail_cont (check): | ||
60 | global success | ||
61 | success= False; | ||
62 | check.evaluate(True) | ||
63 | |||
64 | |||
65 | def check_connect (): | ||
66 | check = Check (test) | ||
67 | check.add (EqualStatisticsCondition (client, 'transport', '# peers connected', client, 'core', '# neighbour entries allocated')) | ||
68 | check.add (EqualStatisticsCondition (client, 'transport', '# peers connected', client, 'core', '# entries in session map')) | ||
69 | check.add (EqualStatisticsCondition (client, 'core', '# neighbour entries allocated', client, 'core', '# entries in session map')) | ||
70 | check.add (EqualStatisticsCondition (client, 'transport', '# peers connected', client, 'topology', '# peers connected')) | ||
71 | check.add (EqualStatisticsCondition (client, 'topology', '# peers connected', client, 'core', '# entries in session map')) | ||
72 | |||
73 | while True: | ||
74 | check.reset() | ||
75 | res = check.run_once (None, None) | ||
76 | print "Values are equal" | ||
77 | check.evaluate (False) | ||
78 | #if (False == res): | ||
79 | # break | ||
80 | time.sleep (5) | ||
81 | |||
82 | # | ||
83 | # Test execution | ||
84 | # | ||
85 | def run (): | ||
86 | global success | ||
87 | global test | ||
88 | global client | ||
89 | |||
90 | |||
91 | success = False | ||
92 | |||
93 | test = Test ('test_integration_connection_value', verbose) | ||
94 | |||
95 | client = Peer(test, './confs/c_normal_client_tcp_udp.conf'); | ||
96 | client.start(); | ||
97 | |||
98 | if (client.started == True): | ||
99 | test.p ('Peers started, running check') | ||
100 | check_connect () | ||
101 | |||
102 | client.stop () | ||
103 | |||
104 | cleanup () | ||
105 | |||
106 | if (success == False): | ||
107 | print ('Test failed') | ||
108 | return False | ||
109 | else: | ||
110 | return True | ||
111 | |||
112 | |||
113 | try: | ||
114 | run () | ||
115 | except (KeyboardInterrupt, SystemExit): | ||
116 | print 'Test interrupted' | ||
117 | client.stop () | ||
118 | cleanup () | ||
119 | if (success == False): | ||
120 | sys.exit(1) | ||
121 | else: | ||
122 | sys.exit(0) | ||
123 | |||
124 | |||
diff --git a/src/integration-tests/test_integration_connection_values_tcp_udp_http.py.in b/src/integration-tests/test_integration_connection_values_tcp_udp_http.py.in new file mode 100755 index 000000000..0916f8540 --- /dev/null +++ b/src/integration-tests/test_integration_connection_values_tcp_udp_http.py.in | |||
@@ -0,0 +1,124 @@ | |||
1 | #!/usr/bin/python | ||
2 | # This file is part of GNUnet. | ||
3 | # (C) 2010 Christian Grothoff (and other contributing authors) | ||
4 | # | ||
5 | # GNUnet is free software; you can redistribute it and/or modify | ||
6 | # it under the terms of the GNU General Public License as published | ||
7 | # by the Free Software Foundation; either version 2, or (at your | ||
8 | # option) any later version. | ||
9 | # | ||
10 | # GNUnet is distributed in the hope that it will be useful, but | ||
11 | # WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
13 | # General Public License for more details. | ||
14 | # | ||
15 | # You should have received a copy of the GNU General Public License | ||
16 | # along with GNUnet; see the file COPYING. If not, write to the | ||
17 | # Free Software Foundation, Inc., 59 Temple Place - Suite 330, | ||
18 | # Boston, MA 02111-1307, USA. | ||
19 | # | ||
20 | # | ||
21 | # | ||
22 | # This test starts 3 peers and expects bootstrap and a connected clique | ||
23 | # | ||
24 | # Conditions for successful exit: | ||
25 | # Both peers have 1 connected peer in transport, core, topology, fs | ||
26 | |||
27 | import sys | ||
28 | import os | ||
29 | import subprocess | ||
30 | import re | ||
31 | import shutil | ||
32 | import time | ||
33 | import pexpect | ||
34 | from gnunet_testing import Peer | ||
35 | from gnunet_testing import Test | ||
36 | from gnunet_testing import Check | ||
37 | from gnunet_testing import Condition | ||
38 | from gnunet_testing import * | ||
39 | |||
40 | |||
41 | #definitions | ||
42 | |||
43 | testname = "test_integration_connection_value" | ||
44 | verbose = True | ||
45 | check_timeout = 30 | ||
46 | |||
47 | |||
48 | def cleanup (): | ||
49 | if os.name == "nt": | ||
50 | shutil.rmtree (os.path.join (os.getenv ("TEMP"), "c_normal_client"), True) | ||
51 | else: | ||
52 | shutil.rmtree ("/tmp/c_normal_client/", True) | ||
53 | |||
54 | |||
55 | def success_cont (check): | ||
56 | global success | ||
57 | success = True; | ||
58 | |||
59 | def fail_cont (check): | ||
60 | global success | ||
61 | success= False; | ||
62 | check.evaluate(True) | ||
63 | |||
64 | |||
65 | def check_connect (): | ||
66 | check = Check (test) | ||
67 | check.add (EqualStatisticsCondition (client, 'transport', '# peers connected', client, 'core', '# neighbour entries allocated')) | ||
68 | check.add (EqualStatisticsCondition (client, 'transport', '# peers connected', client, 'core', '# entries in session map')) | ||
69 | check.add (EqualStatisticsCondition (client, 'core', '# neighbour entries allocated', client, 'core', '# entries in session map')) | ||
70 | check.add (EqualStatisticsCondition (client, 'transport', '# peers connected', client, 'topology', '# peers connected')) | ||
71 | check.add (EqualStatisticsCondition (client, 'topology', '# peers connected', client, 'core', '# entries in session map')) | ||
72 | |||
73 | while True: | ||
74 | check.reset() | ||
75 | res = check.run_once (None, None) | ||
76 | print "Values are equal" | ||
77 | check.evaluate (False) | ||
78 | #if (False == res): | ||
79 | # break | ||
80 | time.sleep (5) | ||
81 | |||
82 | # | ||
83 | # Test execution | ||
84 | # | ||
85 | def run (): | ||
86 | global success | ||
87 | global test | ||
88 | global client | ||
89 | |||
90 | |||
91 | success = False | ||
92 | |||
93 | test = Test ('test_integration_connection_value', verbose) | ||
94 | |||
95 | client = Peer(test, './confs/c_normal_client_tcp_udp_http.conf'); | ||
96 | client.start(); | ||
97 | |||
98 | if (client.started == True): | ||
99 | test.p ('Peers started, running check') | ||
100 | check_connect () | ||
101 | |||
102 | client.stop () | ||
103 | |||
104 | cleanup () | ||
105 | |||
106 | if (success == False): | ||
107 | print ('Test failed') | ||
108 | return False | ||
109 | else: | ||
110 | return True | ||
111 | |||
112 | |||
113 | try: | ||
114 | run () | ||
115 | except (KeyboardInterrupt, SystemExit): | ||
116 | print 'Test interrupted' | ||
117 | client.stop () | ||
118 | cleanup () | ||
119 | if (success == False): | ||
120 | sys.exit(1) | ||
121 | else: | ||
122 | sys.exit(0) | ||
123 | |||
124 | |||