summaryrefslogtreecommitdiff
path: root/ndb/test
diff options
context:
space:
mode:
authorunknown <joreland@mysql.com>2004-12-31 06:14:18 +0100
committerunknown <joreland@mysql.com>2004-12-31 06:14:18 +0100
commit5df5f5c174299fc76e65e8273570f09090b41df5 (patch)
tree5116ea21b23500f78f5ae5b33e504266f590fc0d /ndb/test
parent5bd46150a0d51bc38611796541ee5de8c347a3f9 (diff)
parentee4c910422236fd376df0d9688ce0ca39f61fdfc (diff)
downloadmariadb-git-5df5f5c174299fc76e65e8273570f09090b41df5.tar.gz
Merge joreland@bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/home/jonas/src/mysql-5.0 BitKeeper/etc/logging_ok: auto-union ndb/include/ndbapi/NdbDictionary.hpp: Auto merged ndb/src/common/util/Makefile.am: Auto merged ndb/src/kernel/blocks/backup/Backup.cpp: Auto merged ndb/src/kernel/blocks/backup/Backup.hpp: Auto merged ndb/src/kernel/blocks/backup/BackupInit.cpp: Auto merged ndb/src/kernel/blocks/dbdict/Dbdict.cpp: Auto merged ndb/src/ndbapi/NdbDictionary.cpp: Auto merged ndb/src/ndbapi/NdbDictionaryImpl.cpp: Auto merged ndb/src/ndbapi/TransporterFacade.cpp: Auto merged ndb/src/ndbapi/TransporterFacade.hpp: Auto merged ndb/src/ndbapi/ndberror.c: Auto merged ndb/test/ndbapi/Makefile.am: Auto merged ndb/test/tools/Makefile.am: Auto merged ndb/tools/restore/restore_main.cpp: Auto merged
Diffstat (limited to 'ndb/test')
-rw-r--r--ndb/test/Makefile.am2
-rw-r--r--ndb/test/include/NdbSchemaOp.hpp2
-rw-r--r--ndb/test/ndbapi/Makefile.am61
-rw-r--r--ndb/test/ndbapi/bank/Makefile.am2
-rw-r--r--ndb/test/ndbapi/testDict.cpp6
-rw-r--r--ndb/test/ndbapi/testNdbApi.cpp8
-rw-r--r--ndb/test/ndbapi/testOperations.cpp2
-rw-r--r--ndb/test/run-test/Makefile.am2
-rw-r--r--ndb/test/src/CpcClient.cpp3
-rw-r--r--ndb/test/src/Makefile.am14
-rw-r--r--ndb/test/src/NdbBackup.cpp3
-rw-r--r--ndb/test/src/NdbRestarts.cpp2
-rw-r--r--ndb/test/src/getarg.c3
-rw-r--r--ndb/test/tools/Makefile.am2
14 files changed, 102 insertions, 10 deletions
diff --git a/ndb/test/Makefile.am b/ndb/test/Makefile.am
index 2e0f30df9d4..b8753668c60 100644
--- a/ndb/test/Makefile.am
+++ b/ndb/test/Makefile.am
@@ -4,3 +4,5 @@ EXTRA_DIST = include
dist-hook:
-rm -rf `find $(distdir) -type d -name SCCS`
+
+windoze-dsp:
diff --git a/ndb/test/include/NdbSchemaOp.hpp b/ndb/test/include/NdbSchemaOp.hpp
index 43f76c8c253..ac859f8abe8 100644
--- a/ndb/test/include/NdbSchemaOp.hpp
+++ b/ndb/test/include/NdbSchemaOp.hpp
@@ -303,6 +303,7 @@ public:
*
* @deprecated do not use!
*/
+#ifndef NDB_WIN32
inline int createTable( const char* aTableName,
Uint32 aTableSize,
KeyType aTupleKey,
@@ -324,6 +325,7 @@ public:
aMemoryType,
(aStoredTable == 1 ? true : false));
}
+#endif
/**
* Add a new attribute to a database table.
diff --git a/ndb/test/ndbapi/Makefile.am b/ndb/test/ndbapi/Makefile.am
index 90f0a08d633..33b71b5b91e 100644
--- a/ndb/test/ndbapi/Makefile.am
+++ b/ndb/test/ndbapi/Makefile.am
@@ -88,4 +88,65 @@ testBackup_LDADD = $(LDADD) bank/libbank.a
# Don't update the files from bitkeeper
%::SCCS/s.%
+windoze-dsp: flexBench.dsp testBasic.dsp testBlobs.dsp \
+ testScan.dsp
+flexBench.dsp: Makefile \
+ $(top_srcdir)/ndb/config/win-prg.am \
+ $(top_srcdir)/ndb/config/win-name \
+ $(top_srcdir)/ndb/config/win-includes \
+ $(top_srcdir)/ndb/config/win-sources \
+ $(top_srcdir)/ndb/config/win-libraries
+ cat $(top_srcdir)/ndb/config/win-prg.am > $@
+ @$(top_srcdir)/ndb/config/win-name $@ flexBench
+ @$(top_srcdir)/ndb/config/win-includes $@ $(INCLUDES)
+ @$(top_srcdir)/ndb/config/win-sources $@ $(flexBench_SOURCES)
+ @$(top_srcdir)/ndb/config/win-libraries $@ LINK $(LDADD)
+
+testBasic.dsp: Makefile \
+ $(top_srcdir)/ndb/config/win-prg.am \
+ $(top_srcdir)/ndb/config/win-name \
+ $(top_srcdir)/ndb/config/win-includes \
+ $(top_srcdir)/ndb/config/win-sources \
+ $(top_srcdir)/ndb/config/win-libraries
+ cat $(top_srcdir)/ndb/config/win-prg.am > $@
+ @$(top_srcdir)/ndb/config/win-name $@ testBasic
+ @$(top_srcdir)/ndb/config/win-includes $@ $(INCLUDES)
+ @$(top_srcdir)/ndb/config/win-sources $@ $(testBasic_SOURCES)
+ @$(top_srcdir)/ndb/config/win-libraries $@ LINK $(LDADD)
+
+testOIBasic.dsp: Makefile \
+ $(top_srcdir)/ndb/config/win-prg.am \
+ $(top_srcdir)/ndb/config/win-name \
+ $(top_srcdir)/ndb/config/win-includes \
+ $(top_srcdir)/ndb/config/win-sources \
+ $(top_srcdir)/ndb/config/win-libraries
+ cat $(top_srcdir)/ndb/config/win-prg.am > $@
+ @$(top_srcdir)/ndb/config/win-name $@ testOIBasic
+ @$(top_srcdir)/ndb/config/win-includes $@ $(INCLUDES)
+ @$(top_srcdir)/ndb/config/win-sources $@ $(testOIBasic_SOURCES)
+ @$(top_srcdir)/ndb/config/win-libraries $@ LINK $(LDADD)
+
+testBlobs.dsp: Makefile \
+ $(top_srcdir)/ndb/config/win-prg.am \
+ $(top_srcdir)/ndb/config/win-name \
+ $(top_srcdir)/ndb/config/win-includes \
+ $(top_srcdir)/ndb/config/win-sources \
+ $(top_srcdir)/ndb/config/win-libraries
+ cat $(top_srcdir)/ndb/config/win-prg.am > $@
+ @$(top_srcdir)/ndb/config/win-name $@ testBlobs
+ @$(top_srcdir)/ndb/config/win-includes $@ $(INCLUDES)
+ @$(top_srcdir)/ndb/config/win-sources $@ $(testBlobs_SOURCES)
+ @$(top_srcdir)/ndb/config/win-libraries $@ LINK $(LDADD)
+
+testScan.dsp: Makefile \
+ $(top_srcdir)/ndb/config/win-prg.am \
+ $(top_srcdir)/ndb/config/win-name \
+ $(top_srcdir)/ndb/config/win-includes \
+ $(top_srcdir)/ndb/config/win-sources \
+ $(top_srcdir)/ndb/config/win-libraries
+ cat $(top_srcdir)/ndb/config/win-prg.am > $@
+ @$(top_srcdir)/ndb/config/win-name $@ testScan
+ @$(top_srcdir)/ndb/config/win-includes $@ $(INCLUDES)
+ @$(top_srcdir)/ndb/config/win-sources $@ $(testScan_SOURCES)
+ @$(top_srcdir)/ndb/config/win-libraries $@ LINK $(LDADD)
diff --git a/ndb/test/ndbapi/bank/Makefile.am b/ndb/test/ndbapi/bank/Makefile.am
index 886d664aefb..d4f82a7f9c4 100644
--- a/ndb/test/ndbapi/bank/Makefile.am
+++ b/ndb/test/ndbapi/bank/Makefile.am
@@ -20,3 +20,5 @@ include $(top_srcdir)/ndb/config/type_ndbapitest.mk.am
# Don't update the files from bitkeeper
%::SCCS/s.%
+
+windoze-dsp:
diff --git a/ndb/test/ndbapi/testDict.cpp b/ndb/test/ndbapi/testDict.cpp
index 0a43bb02fff..5f88342705a 100644
--- a/ndb/test/ndbapi/testDict.cpp
+++ b/ndb/test/ndbapi/testDict.cpp
@@ -1211,7 +1211,7 @@ runTableRename(NDBT_Context* ctx, NDBT_Step* step){
const NdbDictionary::Table * oldTable = dict->getTable(pTabName.c_str());
if (oldTable) {
- NdbDictionary::Table newTable = dict->getTableForAlteration(pTabName.c_str());
+ NdbDictionary::Table newTable = *oldTable;
newTable.setName(pTabNewName.c_str());
CHECK2(dict->alterTable(newTable) == 0,
"TableRename failed");
@@ -1280,7 +1280,7 @@ runTableRenameNF(NDBT_Context* ctx, NDBT_Step* step){
const NdbDictionary::Table * oldTable = dict->getTable(pTabName.c_str());
if (oldTable) {
- NdbDictionary::Table newTable = dict->getTableForAlteration(pTabName.c_str());
+ NdbDictionary::Table newTable = *oldTable;
newTable.setName(pTabNewName.c_str());
CHECK2(dict->alterTable(newTable) == 0,
"TableRename failed");
@@ -1377,7 +1377,7 @@ runTableRenameSR(NDBT_Context* ctx, NDBT_Step* step){
const NdbDictionary::Table * oldTable = dict->getTable(pTabName.c_str());
if (oldTable) {
- NdbDictionary::Table newTable = dict->getTableForAlteration(pTabName.c_str());
+ NdbDictionary::Table newTable = *oldTable;
newTable.setName(pTabNewName.c_str());
CHECK2(dict->alterTable(newTable) == 0,
"TableRename failed");
diff --git a/ndb/test/ndbapi/testNdbApi.cpp b/ndb/test/ndbapi/testNdbApi.cpp
index a1ebac609b6..69e534e6860 100644
--- a/ndb/test/ndbapi/testNdbApi.cpp
+++ b/ndb/test/ndbapi/testNdbApi.cpp
@@ -142,14 +142,22 @@ int runTestMaxTransaction(NDBT_Context* ctx, NDBT_Step* step){
4);
break;
case 2:
+ ndbout_c("startTransactionDGroup not supported");
+ abort();
+ /*
pCon = pNdb->startTransactionDGroup(1,
"TEST",
0);
+ */
break;
case 3:
+ ndbout_c("startTransactionDGroup not supported");
+ abort();
+ /*
pCon = pNdb->startTransactionDGroup(2,
"TEST",
1);
+ */
break;
default:
diff --git a/ndb/test/ndbapi/testOperations.cpp b/ndb/test/ndbapi/testOperations.cpp
index f31906dd737..949f08281a5 100644
--- a/ndb/test/ndbapi/testOperations.cpp
+++ b/ndb/test/ndbapi/testOperations.cpp
@@ -171,7 +171,7 @@ runTwoOperations(NDBT_Context* ctx, NDBT_Step* step){
// Insert, read
CHECK(hugoOps.startTransaction(pNdb) == 0);
CHECK(runOp(hugoOps, pNdb, op1, val1) == 0);
- AbortOption oa = (res1 == 0) ? AbortOnError : IgnoreError;
+ AbortOption oa = (res1 == 0) ? AbortOnError : AO_IgnoreError;
CHECK(hugoOps.execute_NoCommit(pNdb, oa) == res1);
CHECK(checkVal(hugoOps, op1, val1, res1) == 0);
diff --git a/ndb/test/run-test/Makefile.am b/ndb/test/run-test/Makefile.am
index c890536dcc6..83dcb3dbbcf 100644
--- a/ndb/test/run-test/Makefile.am
+++ b/ndb/test/run-test/Makefile.am
@@ -23,3 +23,5 @@ wrappers_SCRIPTS=atrt-testBackup atrt-mysql-test-run
# Don't update the files from bitkeeper
%::SCCS/s.%
+
+windoze-dsp:
diff --git a/ndb/test/src/CpcClient.cpp b/ndb/test/src/CpcClient.cpp
index d407ba65312..2ef23528360 100644
--- a/ndb/test/src/CpcClient.cpp
+++ b/ndb/test/src/CpcClient.cpp
@@ -15,9 +15,6 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <ndb_global.h>
-#include <editline/editline.h>
-
-#include <netdb.h>
#include <NdbOut.hpp>
#include <NdbTCP.h>
diff --git a/ndb/test/src/Makefile.am b/ndb/test/src/Makefile.am
index 56f3d6a1ec6..289633b060a 100644
--- a/ndb/test/src/Makefile.am
+++ b/ndb/test/src/Makefile.am
@@ -19,3 +19,17 @@ include $(top_srcdir)/ndb/config/type_ndbapitest.mk.am
# Don't update the files from bitkeeper
%::SCCS/s.%
+
+windoze-dsp: libNDBT.dsp
+
+libNDBT.dsp: Makefile \
+ $(top_srcdir)/ndb/config/win-lib.am \
+ $(top_srcdir)/ndb/config/win-name \
+ $(top_srcdir)/ndb/config/win-includes \
+ $(top_srcdir)/ndb/config/win-sources \
+ $(top_srcdir)/ndb/config/win-libraries
+ cat $(top_srcdir)/ndb/config/win-lib.am > $@
+ @$(top_srcdir)/ndb/config/win-name $@ $(noinst_LIBRARIES)
+ @$(top_srcdir)/ndb/config/win-includes $@ $(INCLUDES)
+ @$(top_srcdir)/ndb/config/win-sources $@ $(libNDBT_a_SOURCES)
+ @$(top_srcdir)/ndb/config/win-libraries $@ LIB
diff --git a/ndb/test/src/NdbBackup.cpp b/ndb/test/src/NdbBackup.cpp
index 09f52bf0bed..5e22468692e 100644
--- a/ndb/test/src/NdbBackup.cpp
+++ b/ndb/test/src/NdbBackup.cpp
@@ -46,7 +46,8 @@ NdbBackup::start(unsigned int & _backup_id){
ndb_mgm_reply reply;
reply.return_code = 0;
- if (ndb_mgm_start_backup(handle,
+ if (ndb_mgm_start_backup(handle,
+ 2, // wait until completed
&_backup_id,
&reply) == -1) {
g_err << "Could not start backup " << endl;
diff --git a/ndb/test/src/NdbRestarts.cpp b/ndb/test/src/NdbRestarts.cpp
index b649a60d98b..607e48c4126 100644
--- a/ndb/test/src/NdbRestarts.cpp
+++ b/ndb/test/src/NdbRestarts.cpp
@@ -445,7 +445,7 @@ int twoNodeFailure(NdbRestarter& _restarter,
<< ") secs " << endl;
NdbSleep_SecSleep(seconds);
- randomId = (random() % _restarter.getNumDbNodes());
+ randomId = (rand() % _restarter.getNumDbNodes());
nodeId = _restarter.getDbNodeId(randomId);
g_info << _restart->m_name << ": node = "<< nodeId << endl;
diff --git a/ndb/test/src/getarg.c b/ndb/test/src/getarg.c
index 9f03af69824..5b67eb6343d 100644
--- a/ndb/test/src/getarg.c
+++ b/ndb/test/src/getarg.c
@@ -35,6 +35,7 @@
#include <ndb_global.h>
#include "getarg.h"
+#include <basestring_vsnprintf.h>
#ifndef HAVE_STRLCPY
static size_t
@@ -293,7 +294,7 @@ arg_printusage (struct getargs *args,
col += fprintf(stderr, " %s", buf);
}
if (args[i].short_name) {
- snprintf(buf, sizeof(buf), "[-%c", args[i].short_name);
+ basestring_snprintf(buf, sizeof(buf), "[-%c", args[i].short_name);
len += 2;
len += print_arg(buf + strlen(buf), sizeof(buf) - strlen(buf),
0, 0, &args[i]);
diff --git a/ndb/test/tools/Makefile.am b/ndb/test/tools/Makefile.am
index 42dc067a473..6b5e127b03d 100644
--- a/ndb/test/tools/Makefile.am
+++ b/ndb/test/tools/Makefile.am
@@ -27,3 +27,5 @@ ndb_cpcc_LDADD = $(LDADD)
# Don't update the files from bitkeeper
%::SCCS/s.%
+
+windoze-dsp: