From 8fa46718eca0b3add79659d89948131cd61672ca Mon Sep 17 00:00:00 2001 From: "jonas@perch.ndb.mysql.com" <> Date: Mon, 23 Apr 2007 15:38:06 +0200 Subject: [PATCH] ndb - add (auto) testcase for bug#28023 --- storage/ndb/test/ndbapi/testNodeRestart.cpp | 69 +++++++++++++++++++ .../ndb/test/run-test/daily-basic-tests.txt | 4 ++ 2 files changed, 73 insertions(+) diff --git a/storage/ndb/test/ndbapi/testNodeRestart.cpp b/storage/ndb/test/ndbapi/testNodeRestart.cpp index 03229ca029f..fb05681bab4 100644 --- a/storage/ndb/test/ndbapi/testNodeRestart.cpp +++ b/storage/ndb/test/ndbapi/testNodeRestart.cpp @@ -1473,6 +1473,72 @@ runBug27466(NDBT_Context* ctx, NDBT_Step* step) return NDBT_OK; } +int +runBug28023(NDBT_Context* ctx, NDBT_Step* step) +{ + int result = NDBT_OK; + int loops = ctx->getNumLoops(); + int records = ctx->getNumRecords(); + Ndb* pNdb = GETNDB(step); + NdbRestarter res; + + if (res.getNumDbNodes() < 2) + { + return NDBT_OK; + } + + + HugoTransactions hugoTrans(*ctx->getTab()); + if (hugoTrans.loadTable(pNdb, records) != 0){ + return NDBT_FAILED; + } + + if (hugoTrans.clearTable(pNdb, records) != 0) + { + return NDBT_FAILED; + } + + for (Uint32 i = 0; i