patch 4.0
This commit is contained in:
@ -14,15 +14,17 @@
|
||||
#include "lib/stat/ob_stat_template.h"
|
||||
#include "lib/stat/ob_session_stat.h"
|
||||
|
||||
namespace oceanbase {
|
||||
namespace common {
|
||||
namespace oceanbase
|
||||
{
|
||||
namespace common
|
||||
{
|
||||
TEST(ObStatArray, normal)
|
||||
{
|
||||
int ret = OB_SUCCESS;
|
||||
ObWaitEventStatArray stats1;
|
||||
ObWaitEventStatArray stats2;
|
||||
ObWaitEventStatArray::Iterator iter;
|
||||
const ObWaitEventStat* item = NULL;
|
||||
const ObWaitEventStat *item = NULL;
|
||||
|
||||
stats1.get(0)->total_waits_ = 1;
|
||||
stats1.get(3)->total_waits_ = 2;
|
||||
@ -41,13 +43,20 @@ TEST(ObStatArray, normal)
|
||||
ASSERT_EQ(3, item->total_waits_);
|
||||
ret = iter.get_next(item);
|
||||
ASSERT_EQ(OB_ITER_END, ret);
|
||||
|
||||
|
||||
}
|
||||
|
||||
} // namespace common
|
||||
} // namespace oceanbase
|
||||
}
|
||||
}
|
||||
|
||||
int main(int argc, char** argv)
|
||||
int main(int argc, char **argv)
|
||||
{
|
||||
testing::InitGoogleTest(&argc, argv);
|
||||
return RUN_ALL_TESTS();
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user