Move subunit infrastructure code into lib/torture.
authorJelmer Vernooij <jelmer@samba.org>
Sun, 27 Apr 2008 13:02:46 +0000 (14:02 +0100)
committerJelmer Vernooij <jelmer@samba.org>
Sun, 27 Apr 2008 13:02:46 +0000 (14:02 +0100)
(This used to be commit 5b44d8121de7735d69e6238a1442aff034a8ebd3)

31 files changed:
source4/lib/basic.mk
source4/lib/crypto/sha1test.c
source4/lib/torture/config.mk [new file with mode: 0644]
source4/lib/torture/torture.c [moved from source4/torture/ui.c with 99% similarity]
source4/lib/torture/torture.h [moved from source4/torture/ui.h with 100% similarity]
source4/lib/util/tests/str.c
source4/torture/basic/base.c
source4/torture/basic/locking.c
source4/torture/basic/misc.c
source4/torture/config.mk
source4/torture/ldap/common.c
source4/torture/libnet/libnet.c
source4/torture/local/dbspeed.c
source4/torture/local/local.c
source4/torture/nbench/nbench.c
source4/torture/nbt/nbt.c
source4/torture/ndr/ndr.c
source4/torture/rap/rap.c
source4/torture/raw/lookuprate.c
source4/torture/raw/raw.c
source4/torture/rpc/rpc.c
source4/torture/rpc/rpc.h
source4/torture/rpc/spoolss_notify.c
source4/torture/rpc/spoolss_win.c
source4/torture/smb2/smb2.c
source4/torture/smbtorture.c
source4/torture/smbtorture.h [moved from source4/torture/torture.h with 91% similarity]
source4/torture/unix/unix.c
source4/torture/util.h
source4/torture/util_smb.c
source4/torture/winbind/winbind.c

index 71acb944923e5f6cf09879683a3a78c2ff4e1f8a..e7e0ba80c4c87993f7790a6417a3e225a4278072 100644 (file)
@@ -16,6 +16,7 @@ mkinclude util/config.mk
 mkinclude tdr/config.mk
 mkinclude dbwrap/config.mk
 mkinclude crypto/config.mk
+mkinclude torture/config.mk
 
 [SUBSYSTEM::LIBCOMPRESSION]
 
index 0e943bd74d7584368ab9cb65da22858987b65cb8..77777642771e3b4b93b854fbb0e3b836658ed77d 100644 (file)
@@ -17,7 +17,7 @@
  */
 
 #include "includes.h"
-#include "torture/ui.h"
+#include "torture/torture.h"
 
 #include "lib/crypto/crypto.h"
 
diff --git a/source4/lib/torture/config.mk b/source4/lib/torture/config.mk
new file mode 100644 (file)
index 0000000..e981ee0
--- /dev/null
@@ -0,0 +1,11 @@
+# TORTURE subsystem
+[LIBRARY::torture]
+PUBLIC_DEPENDENCIES = \
+               LIBSAMBA-HOSTCONFIG \
+               LIBSAMBA-UTIL \
+               LIBTALLOC
+
+PC_FILES += lib/torture/torture.pc
+torture_OBJ_FILES = $(addprefix lib/torture/, torture.o)
+
+PUBLIC_HEADERS += lib/torture/torture.h
similarity index 99%
rename from source4/torture/ui.c
rename to source4/lib/torture/torture.c
index abbd814747666fc11fc8ced46a02ab73d028b721..3f2c7848aa3bbac6267cb14381f1d60fa47fd72a 100644 (file)
@@ -19,7 +19,6 @@
 */
 
 #include "includes.h"
-#include "torture/ui.h"
 #include "torture/torture.h"
 #include "lib/util/dlinklist.h"
 #include "param/param.h"
index a219ef0891dd8c993bc21470992a6e3bcd840755..3bd6a02fdc28ba384ff250e1c0e9640a194bb137 100644 (file)
@@ -20,7 +20,7 @@
 */
 
 #include "includes.h"
-#include "torture/ui.h"
+#include "torture/torture.h"
 
 static bool test_string_sub_simple(struct torture_context *tctx)
 {
index 966d436935ba57fe1ed333cb6b1bc97ff14dc665..2ab3f9ca91640068b68b2ff179084f6ec052249b 100644 (file)
@@ -19,7 +19,7 @@
 */
 
 #include "includes.h"
-#include "torture/torture.h"
+#include "torture/smbtorture.h"
 #include "torture/basic/proto.h"
 #include "libcli/libcli.h"
 #include "libcli/raw/raw_proto.h"
index 2e2585b9766d55533ebed7e5d20c2302fe2f468f..3f399c97efd386457c393644131b99c4aefb6177 100644 (file)
@@ -23,9 +23,8 @@
 #include "includes.h"
 #include "libcli/raw/libcliraw.h"
 #include "libcli/libcli.h"
-#include "torture/ui.h"
+#include "torture/smbtorture.h"
 #include "torture/util.h"
-#include "torture/torture.h"
 #include "system/time.h"
 #include "system/filesys.h"
 
index 188fc1bc69b437849cad8a3e1e1053658321565a..24e0324bc3e303bbe5fc6554b2565e2de3527d44 100644 (file)
@@ -30,7 +30,7 @@
 #include "libcli/resolve/resolve.h"
 #include "auth/credentials/credentials.h"
 #include "librpc/gen_ndr/ndr_nbt.h"
-#include "torture/torture.h"
+#include "torture/smbtorture.h"
 #include "torture/util.h"
 #include "libcli/smb_composite/smb_composite.h"
 #include "libcli/composite/composite.h"
index 1565797609d13e26cdb5d6cc158a57a3c1376fb3..40f6bbf1ed5f6577afcbe3e3883196e3e604453b 100644 (file)
@@ -1,17 +1,3 @@
-# TORTURE subsystem
-[LIBRARY::torture]
-PRIVATE_PROTO_HEADER = proto.h
-PUBLIC_DEPENDENCIES = \
-               LIBSAMBA-HOSTCONFIG \
-               LIBSAMBA-UTIL \
-               LIBTALLOC \
-               LIBPOPT
-
-PC_FILES += torture/torture.pc
-torture_OBJ_FILES = $(addprefix torture/, torture.o ui.o)
-
-PUBLIC_HEADERS += torture/torture.h torture/ui.h
-
 [SUBSYSTEM::TORTURE_UTIL]
 PRIVATE_DEPENDENCIES = LIBCLI_RAW LIBPYTHON smbcalls PROVISION
 PUBLIC_DEPENDENCIES = POPT_CREDENTIALS
@@ -255,8 +241,9 @@ PRIVATE_DEPENDENCIES = \
 # End BINARY smbtorture
 #################################
 
-smbtorture_OBJ_FILES = torture/smbtorture.o
+smbtorture_OBJ_FILES = torture/smbtorture.o torture/torture.o 
 
+PUBLIC_HEADERS += torture/smbtorture.h
 MANPAGES += torture/man/smbtorture.1
 
 #################################
index 5913163822a01fb6409fd7242987ff21e590b757..2c11de729c23f625dfee5ee03c1bc681f935769e 100644 (file)
@@ -22,7 +22,7 @@
 
 #include "includes.h"
 #include "libcli/ldap/ldap_client.h"
-#include "torture/torture.h"
+#include "torture/smbtorture.h"
 #include "torture/ldap/proto.h"
 
 NTSTATUS torture_ldap_bind(struct ldap_connection *conn, const char *userdn, const char *password)
index 3a75ffcae3e345ae0c63ad80977b28b086d4dea5..8c8353e8d6b700d89a14e9d8586e2254c9ff3a63 100644 (file)
@@ -18,7 +18,7 @@
 */
 
 #include "includes.h"
-#include "torture/torture.h"
+#include "torture/smbtorture.h"
 #include "librpc/rpc/dcerpc.h"
 #include "librpc/gen_ndr/security.h"
 #include "librpc/gen_ndr/lsa.h"
index bf88c00e35885d32bbca6912616a86f81cd8e422..017c8568f4fbc91f3d9c745ffddd0ab7c45af117 100644 (file)
@@ -26,7 +26,7 @@
 #include "lib/ldb/include/ldb_errors.h"
 #include "lib/ldb_wrap.h"
 #include "lib/tdb_wrap.h"
-#include "torture/torture.h"
+#include "torture/smbtorture.h"
 #include "param/param.h"
 
 float tdb_speed;
index e4dfadd3d1c8122db2e37ddefe881bfbfaf24ff3..1c3274adcda745368540d12c632ee4b6abfe150c 100644 (file)
@@ -18,7 +18,7 @@
 */
 
 #include "includes.h"
-#include "torture/torture.h"
+#include "torture/smbtorture.h"
 #include "torture/local/proto.h"
 #include "torture/ndr/ndr.h"
 #include "torture/ndr/proto.h"
index e9bd32cce05eb3549d858ad41c862a6011b60ebf..96144c47735592b5af885c7371ce3e0588e133e5 100644 (file)
@@ -19,9 +19,8 @@
 
 #include "includes.h"
 #include "libcli/libcli.h"
-#include "torture/ui.h"
 #include "torture/util.h"
-#include "torture/torture.h"
+#include "torture/smbtorture.h"
 #include "system/filesys.h"
 #include "system/locale.h"
 #include "pstring.h"
index d27a26eb30c34170c7f8a9c5f3a415a1b0e5f37d..422261884f661329487333b2c78067995f41302a 100644 (file)
@@ -21,7 +21,7 @@
 #include "libcli/nbt/libnbt.h"
 #include "torture/torture.h"
 #include "torture/nbt/proto.h"
-#include "torture/ui.h"
+#include "torture/smbtorture.h"
 #include "libcli/resolve/resolve.h"
 #include "param/param.h"
 
index 55b00d1fb80150496aacc81dbd1d6596eadd0ffc..63636f8c5f7856fead65b525a6d8b97a2b454d75 100644 (file)
@@ -21,7 +21,7 @@
 #include "includes.h"
 #include "torture/ndr/ndr.h"
 #include "torture/ndr/proto.h"
-#include "torture/ui.h"
+#include "torture/torture.h"
 #include "util/dlinklist.h"
 #include "param/param.h"
 
index 4b5f4b582c581eb3a18d32db47d2b9092d503962..1ccd1254dddc4f996777029867659fdd9b92d4ed 100644 (file)
@@ -21,7 +21,7 @@
 
 #include "includes.h"
 #include "libcli/libcli.h"
-#include "torture/torture.h"
+#include "torture/smbtorture.h"
 #include "torture/util.h"
 #include "libcli/rap/rap.h"
 #include "libcli/raw/libcliraw.h"
index 0e8f002efb87c94f579a27f05642073cb7d5b156..782cb1b31b74f8dfe859d367c3a36aff8ee1fea3 100644 (file)
@@ -20,7 +20,7 @@
 #include "includes.h"
 #include "param/param.h"
 #include "system/filesys.h"
-#include "torture/torture.h"
+#include "torture/smbtorture.h"
 #include "torture/basic/proto.h"
 #include "libcli/libcli.h"
 #include "torture/util.h"
index 262ed1384bf6a0ab956367346660b55f90bd0034..c6133081b041c2ab3761981ac874a4dd2c641e8d 100644 (file)
 */
 
 #include "includes.h"
-#include "torture/torture.h"
 #include "libcli/raw/libcliraw.h"
-#include "torture/raw/proto.h"
 #include "torture/util.h"
+#include "torture/smbtorture.h"
+#include "torture/raw/proto.h"
 
 NTSTATUS torture_raw_init(void)
 {
index 7c8e78b160f9486f85e5bc6137f311adcb2f578b..fdb88b13dccd4198123d72cfa92f48ce079fc683 100644 (file)
@@ -23,7 +23,7 @@
 #include "lib/cmdline/popt_common.h"
 #include "librpc/rpc/dcerpc.h"
 #include "torture/rpc/rpc.h"
-#include "torture/torture.h"
+#include "torture/smbtorture.h"
 #include "librpc/ndr/ndr_table.h"
 #include "lib/util/dlinklist.h"
 
index d0a07277877887ab10703f2e3f6a49ec504c9fba..48db814b7a375ab56cd630843d3450bffdeb5088 100644 (file)
@@ -28,7 +28,7 @@
 #include "librpc/rpc/dcerpc.h"
 #include "libcli/raw/libcliraw.h"
 #include "torture/rpc/proto.h"
-#include "torture/ui.h"
+#include "torture/torture.h"
 
 struct torture_rpc_tcase {
        struct torture_tcase tcase;
index 19cff53d8479d5dc90eed1923dd1d958513f9642..ab6309d55f8015eb5b7ed645d2603b575befd687 100644 (file)
@@ -21,7 +21,6 @@
 
 #include "includes.h"
 #include "torture/torture.h"
-#include "torture/ui.h"
 #include "torture/rpc/rpc.h"
 #include "librpc/gen_ndr/ndr_spoolss_c.h"
 #include "rpc_server/dcerpc_server.h"
index 9e2921d406bfd120201b3a02babc85f55ac43c09..9ce9fb752637868e84fe48a85adb24c10f2103ce 100644 (file)
@@ -20,7 +20,6 @@
 
 #include "includes.h"
 #include "torture/torture.h"
-#include "torture/ui.h"
 #include "torture/rpc/rpc.h"
 #include "librpc/gen_ndr/ndr_spoolss_c.h"
 #include "rpc_server/dcerpc_server.h"
index f406b7d6e82fd180370cb59dfc1d30507a291967..37eadcf7fd5b006d927e09cc1b8b409c95f88e3b 100644 (file)
@@ -21,7 +21,7 @@
 #include "libcli/smb2/smb2.h"
 #include "libcli/smb2/smb2_calls.h"
 
-#include "torture/torture.h"
+#include "torture/smbtorture.h"
 #include "torture/smb2/proto.h"
 #include "lib/util/dlinklist.h"
 
index 01a55a67f66219bcb09ae083e109f4e19b76ece1..511f58cd7c0fe00c4ce54be01b15b421d9382799 100644 (file)
@@ -30,7 +30,7 @@
 #include "lib/events/events.h"
 #include "dynconfig.h"
 
-#include "torture/torture.h"
+#include "torture/smbtorture.h"
 #include "build.h"
 #include "lib/util/dlinklist.h"
 #include "librpc/rpc/dcerpc.h"
similarity index 91%
rename from source4/torture/torture.h
rename to source4/torture/smbtorture.h
index 26ecdb567b4a7f77de8d537c056dbdd293df2c0e..3b5a573d83f0d9e36675c8ebc847d28a8ff65847 100644 (file)
    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */
 
-#ifndef __TORTURE_H__
-#define __TORTURE_H__
+#ifndef __SMBTORTURE_H__
+#define __SMBTORTURE_H__
 
-#include "torture/ui.h"
+#include "torture/torture.h"
 
 struct smbcli_state;
 
@@ -37,5 +37,4 @@ struct torture_test;
 int torture_init(void);
 bool torture_register_suite(struct torture_suite *suite);
 
-
-#endif /* __TORTURE_H__ */
+#endif /* __SMBTORTURE_H__ */
index 05ea27db026da67650e4f1168bcc3594dee86581..661e3372700185c71ecd9e578295855bbefc6a56 100644 (file)
@@ -18,7 +18,7 @@
 */
 
 #include "includes.h"
-#include "torture/torture.h"
+#include "torture/smbtorture.h"
 #include "torture/unix/proto.h"
 
 NTSTATUS torture_unix_init(void)
index 1009fcf9f11b120194559e232cb61487e50303f0..9dc948ade50232601908cce307968aec4c7fec64 100644 (file)
 #ifndef _TORTURE_PROVISION_H_
 #define _TORTURE_PROVISION_H_
 
+#include "torture/torture.h"
+
+struct smbcli_state;
+struct smbcli_tree;
+
 /**
   setup a directory ready for a test
 */
index c1a20094f385e520828823fd1c414df8f9d7c330..938e7d6c038f9b9af6a6fadd32fdd7990edaa7c0 100644 (file)
@@ -28,7 +28,6 @@
 #include "system/shmem.h"
 #include "system/wait.h"
 #include "system/time.h"
-#include "torture/ui.h"
 #include "torture/torture.h"
 #include "util/dlinklist.h"
 #include "auth/credentials/credentials.h"
index e283602337637cabe0f68a803d72ed1aba41d873..b12e92552edf3464b43dbdb9808a97a372e92603 100644 (file)
@@ -18,7 +18,7 @@
 */
 
 #include "includes.h"
-#include "torture/torture.h"
+#include "torture/smbtorture.h"
 #include "torture/winbind/proto.h"
 
 NTSTATUS torture_winbind_init(void)