]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
CLEANUP: tests: remove sessionhash_test.c and test-cookie-appsess.cfg
authorWilly Tarreau <w@1wt.eu>
Mon, 10 Aug 2015 17:12:52 +0000 (19:12 +0200)
committerWilly Tarreau <w@1wt.eu>
Mon, 10 Aug 2015 17:42:11 +0000 (19:42 +0200)
These won't be usable anymore.

tests/sessionhash_test.c [deleted file]
tests/test-cookie-appsess.cfg [deleted file]

diff --git a/tests/sessionhash_test.c b/tests/sessionhash_test.c
deleted file mode 100644 (file)
index cb05f8c..0000000
+++ /dev/null
@@ -1,54 +0,0 @@
-#include <stdio.h>
-#include <common/sessionhash.h>
-
-int main(int argc, char *argv[])
-{
-       appsess *a, *b, *c, *d, *tmp;
-       struct appsession_hash h;
-       int i;
-
-       a = malloc(sizeof(appsess));
-       b = malloc(sizeof(appsess));
-       c = malloc(sizeof(appsess));
-       d = malloc(sizeof(appsess));
-
-       a->sessid = "abcdefg";
-       b->sessid = "2c";
-       c->sessid = "pe";
-       d->sessid = "abbbbbccccb";
-
-       appsession_hash_init(&h, (void (*)())free);
-       appsession_hash_dump(&h);
-       appsession_hash_insert(&h, a);
-       appsession_hash_insert(&h, b);
-       appsession_hash_insert(&h, c);
-       appsession_hash_insert(&h, d);
-
-       appsession_hash_dump(&h);
-
-       printf("a:     %p\n", a);
-       printf("b:     %p\n", b);
-       printf("c:     %p\n", c);
-       printf("d:     %p\n", d);
-       printf("-------------\n");
-       printf("a:     %p\n", appsession_hash_lookup(&h, "abcdefg"));
-       printf("b:     %p\n", appsession_hash_lookup(&h, "2c"));
-       printf("c:     %p\n", appsession_hash_lookup(&h, "pe"));
-       printf("d:     %p\n", appsession_hash_lookup(&h, "abbbbbccccb"));
-       printf("null:  %p\n", appsession_hash_lookup(&h, "non existant"));
-
-
-       appsession_hash_remove(&h, c);
-       appsession_hash_remove(&h, d);
-
-       appsession_hash_dump(&h);
-
-       printf("-- remove c,d\n");
-       printf("a:     %p\n", appsession_hash_lookup(&h, "abcdefg"));
-       printf("b:     %p\n", appsession_hash_lookup(&h, "2c"));
-       printf("c:     %p\n", appsession_hash_lookup(&h, "pe"));
-       printf("d:     %p\n", appsession_hash_lookup(&h, "abbbbbccccb"));
-       printf("null:  %p\n", appsession_hash_lookup(&h, "non existant"));
-
-       appsession_hash_destroy(&h);
-}
diff --git a/tests/test-cookie-appsess.cfg b/tests/test-cookie-appsess.cfg
deleted file mode 100644 (file)
index 61e9dbf..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-# Test configuration. It listens on port 8000, forwards to
-# local ports 8001/8002 as two distinct servers, and relies
-# on a server running on local port 8080 to handle the request.
-
-global
-       maxconn 500
-       stats socket /tmp/sock1 mode 777 level admin
-       stats timeout 1d
-
-defaults
-       mode    http
-       option  http-server-close
-       timeout client 30s
-       timeout server 30s
-       timeout connect 5s
-
-listen test
-       log 127.0.0.1 local0
-       option httplog
-       bind :8000
-       appsession AS len 64 timeout 3h
-       cookie SID insert indirect
-       server s1 127.0.0.1:8001 cookie s1
-       server s2 127.0.0.1:8002 cookie s2
-       capture cookie toto= len 10
-
-listen s1
-       bind 127.0.0.1:8001
-       server srv 127.0.0.1:8080
-       reqadd x-haproxy-used:\ s1
-
-listen s2
-       bind 127.0.0.1:8002
-       server srv 127.0.0.1:8080
-       reqadd x-haproxy-used:\ s2
-