when "CRIMSON_COMPAT" is set, to skip EC and some test cases.
Signed-off-by: chunmei-liu <chunmei.liu@intel.com>
#include "gtest/gtest.h"
#include "test.h"
+#include "crimson_utils.h"
using std::ostringstream;
};
TEST(LibRadosAioEC, SimpleWrite) {
+ SKIP_IF_CRIMSON();
AioTestDataEC test_data;
rados_completion_t my_completion;
ASSERT_EQ("", test_data.init());
}
TEST(LibRadosAioEC, WaitForComplete) {
+ SKIP_IF_CRIMSON();
AioTestDataEC test_data;
rados_completion_t my_completion;
ASSERT_EQ("", test_data.init());
}
TEST(LibRadosAioEC, RoundTrip) {
+ SKIP_IF_CRIMSON();
AioTestDataEC test_data;
rados_completion_t my_completion;
ASSERT_EQ("", test_data.init());
}
TEST(LibRadosAioEC, RoundTrip2) {
+ SKIP_IF_CRIMSON();
AioTestDataEC test_data;
rados_completion_t my_completion;
ASSERT_EQ("", test_data.init());
}
TEST(LibRadosAioEC, RoundTripAppend) {
+ SKIP_IF_CRIMSON();
AioTestDataEC test_data;
rados_completion_t my_completion, my_completion2, my_completion3, my_completion4;
ASSERT_EQ("", test_data.init());
}
TEST(LibRadosAioEC, IsComplete) {
+ SKIP_IF_CRIMSON();
AioTestDataEC test_data;
rados_completion_t my_completion;
ASSERT_EQ("", test_data.init());
}
TEST(LibRadosAioEC, IsSafe) {
+ SKIP_IF_CRIMSON();
AioTestDataEC test_data;
rados_completion_t my_completion;
ASSERT_EQ("", test_data.init());
}
TEST(LibRadosAioEC, ReturnValue) {
+ SKIP_IF_CRIMSON();
AioTestDataEC test_data;
rados_completion_t my_completion;
ASSERT_EQ("", test_data.init());
}
TEST(LibRadosAioEC, Flush) {
+ SKIP_IF_CRIMSON();
AioTestDataEC test_data;
rados_completion_t my_completion;
ASSERT_EQ("", test_data.init());
}
TEST(LibRadosAioEC, FlushAsync) {
+ SKIP_IF_CRIMSON();
AioTestDataEC test_data;
rados_completion_t my_completion;
ASSERT_EQ("", test_data.init());
}
TEST(LibRadosAioEC, RoundTripWriteFull) {
+ SKIP_IF_CRIMSON();
AioTestDataEC test_data;
rados_completion_t my_completion, my_completion2, my_completion3;
ASSERT_EQ("", test_data.init());
}
TEST(LibRadosAioEC, SimpleStat) {
+ SKIP_IF_CRIMSON();
AioTestDataEC test_data;
rados_completion_t my_completion;
ASSERT_EQ("", test_data.init());
TEST(LibRadosAioEC, SimpleStatNS) {
+ SKIP_IF_CRIMSON();
AioTestDataEC test_data;
rados_completion_t my_completion;
ASSERT_EQ("", test_data.init());
}
TEST(LibRadosAioEC, StatRemove) {
+ SKIP_IF_CRIMSON();
AioTestDataEC test_data;
rados_completion_t my_completion;
ASSERT_EQ("", test_data.init());
}
TEST(LibRadosAioEC, ExecuteClass) {
+ SKIP_IF_CRIMSON();
AioTestDataEC test_data;
rados_completion_t my_completion;
ASSERT_EQ("", test_data.init());
}
TEST(LibRadosAioEC, MultiWrite) {
+ SKIP_IF_CRIMSON();
AioTestDataEC test_data;
rados_completion_t my_completion, my_completion2, my_completion3;
ASSERT_EQ("", test_data.init());
#include "common/ceph_mutex.h"
#include "test_cxx.h"
+#include "crimson_utils.h"
using namespace std;
using namespace librados;
// EC test cases
TEST(LibRadosAioEC, SimpleWritePP) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl1;
}
TEST(LibRadosAioEC, WaitForSafePP) {
+ SKIP_IF_CRIMSON();
AioTestDataECPP test_data;
ASSERT_EQ("", test_data.init());
auto my_completion = std::unique_ptr<AioCompletion>{Rados::aio_create_completion()};
}
TEST(LibRadosAioEC, RoundTripPP) {
+ SKIP_IF_CRIMSON();
AioTestDataECPP test_data;
ASSERT_EQ("", test_data.init());
auto my_completion = std::unique_ptr<AioCompletion>{Rados::aio_create_completion()};
}
TEST(LibRadosAioEC, RoundTripPP2) {
+ SKIP_IF_CRIMSON();
AioTestDataECPP test_data;
ASSERT_EQ("", test_data.init());
auto my_completion = std::unique_ptr<AioCompletion>{Rados::aio_create_completion()};
//using ObjectWriteOperation/ObjectReadOperation with iohint
TEST(LibRadosAioEC, RoundTripPP3)
{
+ SKIP_IF_CRIMSON();
Rados cluster;
std::string pool_name = get_temp_pool_name();
ASSERT_EQ("", create_one_pool_pp(pool_name, cluster));
}
TEST(LibRadosAioEC, RoundTripSparseReadPP) {
+ SKIP_IF_CRIMSON();
AioTestDataECPP test_data;
ASSERT_EQ("", test_data.init());
auto my_completion = std::unique_ptr<AioCompletion>{Rados::aio_create_completion()};
}
TEST(LibRadosAioEC, RoundTripAppendPP) {
+ SKIP_IF_CRIMSON();
AioTestDataECPP test_data;
ASSERT_EQ("", test_data.init());
auto my_completion = std::unique_ptr<AioCompletion>{Rados::aio_create_completion()};
}
TEST(LibRadosAioEC, IsCompletePP) {
+ SKIP_IF_CRIMSON();
AioTestDataECPP test_data;
ASSERT_EQ("", test_data.init());
auto my_completion = std::unique_ptr<AioCompletion>{Rados::aio_create_completion()};
ASSERT_EQ(0, memcmp(buf, bl2.c_str(), sizeof(buf)));
}
TEST(LibRadosAioEC, IsSafePP) {
+ SKIP_IF_CRIMSON();
AioTestDataECPP test_data;
ASSERT_EQ("", test_data.init());
auto my_completion = std::unique_ptr<AioCompletion>{Rados::aio_create_completion()};
}
TEST(LibRadosAioEC, ReturnValuePP) {
+ SKIP_IF_CRIMSON();
AioTestDataECPP test_data;
ASSERT_EQ("", test_data.init());
auto my_completion = std::unique_ptr<AioCompletion>{Rados::aio_create_completion()};
}
TEST(LibRadosAioEC, FlushPP) {
+ SKIP_IF_CRIMSON();
AioTestDataECPP test_data;
ASSERT_EQ("", test_data.init());
auto my_completion = std::unique_ptr<AioCompletion>{Rados::aio_create_completion()};
}
TEST(LibRadosAioEC, FlushAsyncPP) {
+ SKIP_IF_CRIMSON();
AioTestDataECPP test_data;
ASSERT_EQ("", test_data.init());
auto my_completion = std::unique_ptr<AioCompletion>{Rados::aio_create_completion()};
}
TEST(LibRadosAioEC, RoundTripWriteFullPP) {
+ SKIP_IF_CRIMSON();
AioTestDataECPP test_data;
ASSERT_EQ("", test_data.init());
auto my_completion = std::unique_ptr<AioCompletion>{Rados::aio_create_completion()};
//using ObjectWriteOperation/ObjectReadOperation with iohint
TEST(LibRadosAioEC, RoundTripWriteFullPP2)
{
+ SKIP_IF_CRIMSON();
Rados cluster;
std::string pool_name = get_temp_pool_name();
ASSERT_EQ("", create_one_pool_pp(pool_name, cluster));
}
TEST(LibRadosAioEC, SimpleStatPP) {
+ SKIP_IF_CRIMSON();
AioTestDataECPP test_data;
ASSERT_EQ("", test_data.init());
auto my_completion = std::unique_ptr<AioCompletion>{Rados::aio_create_completion()};
}
TEST(LibRadosAioEC, SimpleStatPPNS) {
+ SKIP_IF_CRIMSON();
AioTestDataECPP test_data;
ASSERT_EQ("", test_data.init());
auto my_completion = std::unique_ptr<AioCompletion>{Rados::aio_create_completion()};
}
TEST(LibRadosAioEC, StatRemovePP) {
+ SKIP_IF_CRIMSON();
AioTestDataECPP test_data;
ASSERT_EQ("", test_data.init());
auto my_completion = std::unique_ptr<AioCompletion>{Rados::aio_create_completion()};
}
TEST(LibRadosAioEC, ExecuteClassPP) {
+ SKIP_IF_CRIMSON();
AioTestDataECPP test_data;
ASSERT_EQ("", test_data.init());
auto my_completion = std::unique_ptr<AioCompletion>{Rados::aio_create_completion()};
}
TEST(LibRadosAioEC, OmapPP) {
+ SKIP_IF_CRIMSON();
Rados cluster;
std::string pool_name = get_temp_pool_name();
ASSERT_EQ("", create_one_ec_pool_pp(pool_name, cluster));
}
TEST(LibRadosAioEC, MultiWritePP) {
+ SKIP_IF_CRIMSON();
AioTestDataECPP test_data;
ASSERT_EQ("", test_data.init());
auto my_completion = std::unique_ptr<AioCompletion>{Rados::aio_create_completion()};
#include "gtest/gtest.h"
#include "test/librados/test_cxx.h"
+#include "crimson_utils.h"
+
using namespace librados;
TEST(ClsTestRemoteReads, TestGather) {
+ SKIP_IF_CRIMSON();
Rados cluster;
std::string pool_name = get_temp_pool_name();
ASSERT_EQ("", create_one_pool_pp(pool_name, cluster));
--- /dev/null
+// -*- mode:C++; tab-width:8; c-basic-offset:2; indent-tabs-mode:t -*-
+// vim: ts=8 sw=2 smarttab
+
+#pragma once
+
+#include <cstdlib>
+
+bool is_crimson_cluster() {
+ return (getenv("CRIMSON_COMPAT") != nullptr);
+}
+
+#define SKIP_IF_CRIMSON() \
+ if (is_crimson_cluster()) { \
+ GTEST_SKIP() << "Not supported by crimson yet. Skipped"; \
+ }
#include <errno.h>
#include "gtest/gtest.h"
+#include "crimson_utils.h"
using std::string;
}
TEST_F(LibRadosIoEC, SimpleWrite) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xcc, sizeof(buf));
ASSERT_EQ(0, rados_write(ioctx, "foo", buf, sizeof(buf), 0));
}
TEST_F(LibRadosIoEC, RoundTrip) {
+ SKIP_IF_CRIMSON();
char buf[128];
char buf2[128];
memset(buf, 0xcc, sizeof(buf));
}
TEST_F(LibRadosIoEC, OverlappingWriteRoundTrip) {
+ SKIP_IF_CRIMSON();
int bsize = alignment;
int dbsize = bsize * 2;
char *buf = (char *)new char[dbsize];
}
TEST_F(LibRadosIoEC, WriteFullRoundTrip) {
+ SKIP_IF_CRIMSON();
char buf[128];
char buf2[64];
char buf3[128];
}
TEST_F(LibRadosIoEC, AppendRoundTrip) {
+ SKIP_IF_CRIMSON();
char *buf = (char *)new char[alignment];
char *buf2 = (char *)new char[alignment];
char *buf3 = (char *)new char[alignment *2];
}
TEST_F(LibRadosIoEC, TruncTest) {
+ SKIP_IF_CRIMSON();
char buf[128];
char buf2[sizeof(buf)];
memset(buf, 0xaa, sizeof(buf));
}
TEST_F(LibRadosIoEC, RemoveTest) {
+ SKIP_IF_CRIMSON();
char buf[128];
char buf2[sizeof(buf)];
memset(buf, 0xaa, sizeof(buf));
}
TEST_F(LibRadosIoEC, XattrsRoundTrip) {
+ SKIP_IF_CRIMSON();
char buf[128];
char attr1[] = "attr1";
char attr1_buf[] = "foo bar baz";
}
TEST_F(LibRadosIoEC, RmXattr) {
+ SKIP_IF_CRIMSON();
char buf[128];
char attr1[] = "attr1";
char attr1_buf[] = "foo bar baz";
}
TEST_F(LibRadosIoEC, XattrIter) {
+ SKIP_IF_CRIMSON();
char buf[128];
char attr1[] = "attr1";
char attr1_buf[] = "foo bar baz";
#include "test/librados/test_cxx.h"
#include "test/librados/testcase_cxx.h"
+#include "crimson_utils.h"
+
using namespace librados;
using std::string;
}
TEST_F(LibRadosIoECPP, SimpleWritePP) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl;
}
TEST_F(LibRadosIoECPP, ReadOpPP) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl;
}
TEST_F(LibRadosIoECPP, SparseReadOpPP) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl;
}
TEST_F(LibRadosIoECPP, RoundTripPP) {
+ SKIP_IF_CRIMSON();
char buf[128];
Rados cluster;
memset(buf, 0xcc, sizeof(buf));
TEST_F(LibRadosIoECPP, RoundTripPP2)
{
+ SKIP_IF_CRIMSON();
bufferlist bl;
bl.append("ceph");
ObjectWriteOperation write;
}
TEST_F(LibRadosIoECPP, OverlappingWriteRoundTripPP) {
+ SKIP_IF_CRIMSON();
int bsize = alignment;
int dbsize = bsize * 2;
char *buf = (char *)new char[dbsize];
}
TEST_F(LibRadosIoECPP, WriteFullRoundTripPP) {
+ SKIP_IF_CRIMSON();
char buf[128];
char buf2[64];
memset(buf, 0xcc, sizeof(buf));
TEST_F(LibRadosIoECPP, WriteFullRoundTripPP2)
{
+ SKIP_IF_CRIMSON();
bufferlist bl;
bl.append("ceph");
ObjectWriteOperation write;
}
TEST_F(LibRadosIoECPP, AppendRoundTripPP) {
+ SKIP_IF_CRIMSON();
char *buf = (char *)new char[alignment];
char *buf2 = (char *)new char[alignment];
auto cleanup = [&] {
}
TEST_F(LibRadosIoECPP, TruncTestPP) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xaa, sizeof(buf));
bufferlist bl;
}
TEST_F(LibRadosIoECPP, RemoveTestPP) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xaa, sizeof(buf));
bufferlist bl1;
}
TEST_F(LibRadosIoECPP, XattrsRoundTripPP) {
+ SKIP_IF_CRIMSON();
char buf[128];
char attr1[] = "attr1";
char attr1_buf[] = "foo bar baz";
}
TEST_F(LibRadosIoECPP, RmXattrPP) {
+ SKIP_IF_CRIMSON();
char buf[128];
char attr1[] = "attr1";
char attr1_buf[] = "foo bar baz";
}
TEST_F(LibRadosIoECPP, XattrListPP) {
+ SKIP_IF_CRIMSON();
char buf[128];
char attr1[] = "attr1";
char attr1_buf[] = "foo bar baz";
}
TEST_F(LibRadosIoECPP, CmpExtPP) {
+ SKIP_IF_CRIMSON();
bufferlist bl;
bl.append("ceph");
ObjectWriteOperation write1;
}
TEST_F(LibRadosIoECPP, CmpExtDNEPP) {
+ SKIP_IF_CRIMSON();
bufferlist bl;
bl.append(std::string(4, '\0'));
}
TEST_F(LibRadosIoECPP, CmpExtMismatchPP) {
+ SKIP_IF_CRIMSON();
bufferlist bl;
bl.append("ceph");
ObjectWriteOperation write1;
#include <string>
#include <stdexcept>
+#include "crimson_utils.h"
+
using namespace std;
using namespace librados;
}
TEST_F(LibRadosListEC, ListObjects) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xcc, sizeof(buf));
ASSERT_EQ(0, rados_write(ioctx, "foo", buf, sizeof(buf), 0));
}
TEST_F(LibRadosListEC, ListObjectsNS) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xcc, sizeof(buf));
// Create :foo1, :foo2, :foo3, n1:foo1, ns1:foo4, ns1:foo5, ns2:foo6, n2:foo7
TEST_F(LibRadosListEC, ListObjectsStart) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xcc, sizeof(buf));
// Ensure a non-power-of-two PG count to avoid only
// touching the easy path.
- ASSERT_TRUE(set_pg_num(&s_cluster, pool_name, 11).empty());
- ASSERT_TRUE(set_pgp_num(&s_cluster, pool_name, 11).empty());
-
+ if (!is_crimson_cluster()) {
+ ASSERT_TRUE(set_pg_num(&s_cluster, pool_name, 11).empty());
+ ASSERT_TRUE(set_pgp_num(&s_cluster, pool_name, 11).empty());
+ }
std::set<std::string> saw_obj;
rados_object_list_cursor c = rados_object_list_begin(ioctx);
rados_object_list_cursor end = rados_object_list_end(ioctx);
// Ensure a non-power-of-two PG count to avoid only
// touching the easy path.
- if (auto error = set_pg_num(&s_cluster, pool_name, 11); !error.empty()) {
- GTEST_FAIL() << error;
- }
- if (auto error = set_pgp_num(&s_cluster, pool_name, 11); !error.empty()) {
- GTEST_FAIL() << error;
+ if (!is_crimson_cluster()) {
+ if (auto error = set_pg_num(&s_cluster, pool_name, 11); !error.empty()) {
+ GTEST_FAIL() << error;
+ }
+ if (auto error = set_pgp_num(&s_cluster, pool_name, 11); !error.empty()) {
+ GTEST_FAIL() << error;
+ }
}
rados_object_list_cursor begin = rados_object_list_begin(ioctx);
#include "test/librados/testcase_cxx.h"
#include "global/global_context.h"
+#include "crimson_utils.h"
+
using namespace librados;
typedef RadosTestPPNSCleanup LibRadosListPP;
}
TEST_F(LibRadosListECPP, ListObjectsPP) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl1;
}
TEST_F(LibRadosListECPP, ListObjectsTwicePP) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl1;
}
TEST_F(LibRadosListECPP, ListObjectsCopyIterPP) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl1;
}
TEST_F(LibRadosListECPP, ListObjectsEndIter) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl1;
}
TEST_F(LibRadosListECPP, ListObjectsPPNS) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl1;
}
TEST_F(LibRadosListECPP, ListObjectsManyPP) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl;
}
TEST_F(LibRadosListECPP, ListObjectsStartPP) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl;
#include "gtest/gtest.h"
#include <sys/time.h>
+#include "crimson_utils.h"
+
using namespace std::chrono_literals;
typedef RadosTest LibRadosLock;
// EC testing
TEST_F(LibRadosLockEC, LockExclusive) {
+ SKIP_IF_CRIMSON();
ASSERT_EQ(0, rados_lock_exclusive(ioctx, "foo", "TestLockEC1", "Cookie", "", NULL, 0));
ASSERT_EQ(-EEXIST, rados_lock_exclusive(ioctx, "foo", "TestLockEC1", "Cookie", "", NULL, 0));
}
TEST_F(LibRadosLockEC, LockShared) {
+ SKIP_IF_CRIMSON();
ASSERT_EQ(0, rados_lock_shared(ioctx, "foo", "TestLockEC2", "Cookie", "Tag", "", NULL, 0));
ASSERT_EQ(-EEXIST, rados_lock_shared(ioctx, "foo", "TestLockEC2", "Cookie", "Tag", "", NULL, 0));
}
TEST_F(LibRadosLockEC, LockExclusiveDur) {
+ SKIP_IF_CRIMSON();
struct timeval tv;
tv.tv_sec = 1;
tv.tv_usec = 0;
}
TEST_F(LibRadosLockEC, LockSharedDur) {
+ SKIP_IF_CRIMSON();
struct timeval tv;
tv.tv_sec = 1;
tv.tv_usec = 0;
TEST_F(LibRadosLockEC, LockMayRenew) {
+ SKIP_IF_CRIMSON();
ASSERT_EQ(0, rados_lock_exclusive(ioctx, "foo", "TestLockEC5", "Cookie", "", NULL, 0));
ASSERT_EQ(-EEXIST, rados_lock_exclusive(ioctx, "foo", "TestLockEC5", "Cookie", "", NULL, 0));
ASSERT_EQ(0, rados_lock_exclusive(ioctx, "foo", "TestLockEC5", "Cookie", "", NULL, LOCK_FLAG_MAY_RENEW));
}
TEST_F(LibRadosLockEC, Unlock) {
+ SKIP_IF_CRIMSON();
ASSERT_EQ(0, rados_lock_exclusive(ioctx, "foo", "TestLockEC6", "Cookie", "", NULL, 0));
ASSERT_EQ(0, rados_unlock(ioctx, "foo", "TestLockEC6", "Cookie"));
ASSERT_EQ(0, rados_lock_exclusive(ioctx, "foo", "TestLockEC6", "Cookie", "", NULL, 0));
}
TEST_F(LibRadosLockEC, ListLockers) {
+ SKIP_IF_CRIMSON();
int exclusive;
char tag[1024];
char clients[1024];
}
TEST_F(LibRadosLockEC, BreakLock) {
+ SKIP_IF_CRIMSON();
int exclusive;
char tag[1024];
char clients[1024];
#include "test/librados/test_cxx.h"
#include "test/librados/testcase_cxx.h"
+#include "crimson_utils.h"
+
using namespace std::chrono_literals;
using namespace librados;
// EC testing
TEST_F(LibRadosLockECPP, LockExclusivePP) {
+ SKIP_IF_CRIMSON();
ASSERT_EQ(0, ioctx.lock_exclusive("foo", "TestLockECPP1", "Cookie", "", NULL, 0));
ASSERT_EQ(-EEXIST, ioctx.lock_exclusive("foo", "TestLockECPP1", "Cookie", "", NULL, 0));
}
TEST_F(LibRadosLockECPP, LockSharedPP) {
+ SKIP_IF_CRIMSON();
ASSERT_EQ(0, ioctx.lock_shared("foo", "TestLockECPP2", "Cookie", "Tag", "", NULL, 0));
ASSERT_EQ(-EEXIST, ioctx.lock_shared("foo", "TestLockECPP2", "Cookie", "Tag", "", NULL, 0));
}
TEST_F(LibRadosLockECPP, LockExclusiveDurPP) {
+ SKIP_IF_CRIMSON();
struct timeval tv;
tv.tv_sec = 1;
tv.tv_usec = 0;
}
TEST_F(LibRadosLockECPP, LockSharedDurPP) {
+ SKIP_IF_CRIMSON();
struct timeval tv;
tv.tv_sec = 1;
tv.tv_usec = 0;
}
TEST_F(LibRadosLockECPP, LockMayRenewPP) {
+ SKIP_IF_CRIMSON();
ASSERT_EQ(0, ioctx.lock_exclusive("foo", "TestLockECPP5", "Cookie", "", NULL, 0));
ASSERT_EQ(-EEXIST, ioctx.lock_exclusive("foo", "TestLockECPP5", "Cookie", "", NULL, 0));
ASSERT_EQ(0, ioctx.lock_exclusive("foo", "TestLockECPP5", "Cookie", "", NULL, LOCK_FLAG_MAY_RENEW));
}
TEST_F(LibRadosLockECPP, UnlockPP) {
+ SKIP_IF_CRIMSON();
ASSERT_EQ(0, ioctx.lock_exclusive("foo", "TestLockECPP6", "Cookie", "", NULL, 0));
ASSERT_EQ(0, ioctx.unlock("foo", "TestLockECPP6", "Cookie"));
ASSERT_EQ(0, ioctx.lock_exclusive("foo", "TestLockECPP6", "Cookie", "", NULL, 0));
}
TEST_F(LibRadosLockECPP, ListLockersPP) {
+ SKIP_IF_CRIMSON();
std::stringstream sstm;
sstm << "client." << cluster.get_instance_id();
std::string me = sstm.str();
}
TEST_F(LibRadosLockECPP, BreakLockPP) {
+ SKIP_IF_CRIMSON();
int exclusive;
std::string tag;
std::list<librados::locker_t> lockers;
#include "test/librados/testcase_cxx.h"
#include "test/librados/test_cxx.h"
+#include "crimson_utils.h"
+
using namespace std;
using namespace librados;
}
TEST_F(LibRadosMiscPP, CopyPP) {
+ SKIP_IF_CRIMSON();
bufferlist bl, x;
bl.append("hi there");
x.append("bar");
//copy_from between ecpool and no-ecpool.
TEST_F(LibRadosTwoPoolsECPP, CopyFrom) {
+ SKIP_IF_CRIMSON();
bufferlist z;
z.append_zero(4194304*2);
bufferlist b;
}
TEST_F(LibRadosMiscPP, CopyScrubPP) {
+ SKIP_IF_CRIMSON();
bufferlist inbl, bl, x;
for (int i=0; i<100; ++i)
x.append("barrrrrrrrrrrrrrrrrrrrrrrrrr");
}
TEST_F(LibRadosMiscECPP, CompareExtentRange) {
+ SKIP_IF_CRIMSON();
bufferlist bl1;
bl1.append("ceph");
ObjectWriteOperation write;
#include "include/rados.h"
#include "test/librados/test.h"
#include "test/librados/TestCase.h"
+#include "crimson_utils.h"
#include <algorithm>
#include <errno.h>
const int bufsize = 128;
TEST_F(LibRadosSnapshots, SnapList) {
+ SKIP_IF_CRIMSON();
char buf[bufsize];
memset(buf, 0xcc, sizeof(buf));
ASSERT_EQ(0, rados_write(ioctx, "foo", buf, sizeof(buf), 0));
}
TEST_F(LibRadosSnapshots, SnapRemove) {
+ SKIP_IF_CRIMSON();
char buf[bufsize];
memset(buf, 0xcc, sizeof(buf));
ASSERT_EQ(0, rados_write(ioctx, "foo", buf, sizeof(buf), 0));
}
TEST_F(LibRadosSnapshots, Rollback) {
+ SKIP_IF_CRIMSON();
char buf[bufsize];
memset(buf, 0xcc, sizeof(buf));
ASSERT_EQ(0, rados_write(ioctx, "foo", buf, sizeof(buf), 0));
}
TEST_F(LibRadosSnapshots, SnapGetName) {
+ SKIP_IF_CRIMSON();
char buf[bufsize];
memset(buf, 0xcc, sizeof(buf));
ASSERT_EQ(0, rados_write(ioctx, "foo", buf, sizeof(buf), 0));
}
TEST_F(LibRadosSnapshotsSelfManaged, Snap) {
+ SKIP_IF_CRIMSON();
std::vector<uint64_t> my_snaps;
my_snaps.push_back(-2);
ASSERT_EQ(0, rados_ioctx_selfmanaged_snap_create(ioctx, &my_snaps.back()));
}
TEST_F(LibRadosSnapshotsSelfManaged, Rollback) {
+ SKIP_IF_CRIMSON();
std::vector<uint64_t> my_snaps;
my_snaps.push_back(-2);
ASSERT_EQ(0, rados_ioctx_selfmanaged_snap_create(ioctx, &my_snaps.back()));
// EC testing
TEST_F(LibRadosSnapshotsEC, SnapList) {
+ SKIP_IF_CRIMSON();
char buf[bufsize];
memset(buf, 0xcc, sizeof(buf));
ASSERT_EQ(0, rados_write(ioctx, "foo", buf, sizeof(buf), 0));
}
TEST_F(LibRadosSnapshotsEC, SnapRemove) {
+ SKIP_IF_CRIMSON();
char buf[bufsize];
memset(buf, 0xcc, sizeof(buf));
ASSERT_EQ(0, rados_write(ioctx, "foo", buf, sizeof(buf), 0));
}
TEST_F(LibRadosSnapshotsEC, Rollback) {
+ SKIP_IF_CRIMSON();
char buf[bufsize];
memset(buf, 0xcc, sizeof(buf));
ASSERT_EQ(0, rados_write(ioctx, "foo", buf, sizeof(buf), 0));
}
TEST_F(LibRadosSnapshotsEC, SnapGetName) {
+ SKIP_IF_CRIMSON();
char buf[bufsize];
memset(buf, 0xcc, sizeof(buf));
ASSERT_EQ(0, rados_write(ioctx, "foo", buf, sizeof(buf), 0));
}
TEST_F(LibRadosSnapshotsSelfManagedEC, Snap) {
+ SKIP_IF_CRIMSON();
std::vector<uint64_t> my_snaps;
my_snaps.push_back(-2);
ASSERT_EQ(0, rados_ioctx_selfmanaged_snap_create(ioctx, &my_snaps.back()));
}
TEST_F(LibRadosSnapshotsSelfManagedEC, Rollback) {
+ SKIP_IF_CRIMSON();
std::vector<uint64_t> my_snaps;
my_snaps.push_back(-2);
ASSERT_EQ(0, rados_ioctx_selfmanaged_snap_create(ioctx, &my_snaps.back()));
#include "include/rados/librados.hpp"
#include "test/librados/test_cxx.h"
#include "test/librados/testcase_cxx.h"
+#include "crimson_utils.h"
using namespace librados;
const int bufsize = 128;
TEST_F(LibRadosSnapshotsPP, SnapListPP) {
+ SKIP_IF_CRIMSON();
char buf[bufsize];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl1;
}
TEST_F(LibRadosSnapshotsPP, SnapRemovePP) {
+ SKIP_IF_CRIMSON();
char buf[bufsize];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl1;
}
TEST_F(LibRadosSnapshotsPP, RollbackPP) {
+ SKIP_IF_CRIMSON();
char buf[bufsize];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl1;
}
TEST_F(LibRadosSnapshotsPP, SnapGetNamePP) {
+ SKIP_IF_CRIMSON();
char buf[bufsize];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl;
}
TEST_F(LibRadosSnapshotsPP, SnapCreateRemovePP) {
+ SKIP_IF_CRIMSON();
// reproduces http://tracker.ceph.com/issues/10262
bufferlist bl;
bl.append("foo");
}
TEST_F(LibRadosSnapshotsSelfManagedPP, SnapPP) {
+ SKIP_IF_CRIMSON();
std::vector<uint64_t> my_snaps;
my_snaps.push_back(-2);
ASSERT_FALSE(cluster.get_pool_is_selfmanaged_snaps_mode(pool_name));
}
TEST_F(LibRadosSnapshotsSelfManagedPP, RollbackPP) {
+ SKIP_IF_CRIMSON();
std::vector<uint64_t> my_snaps;
IoCtx readioctx;
ASSERT_EQ(0, cluster.ioctx_create(pool_name.c_str(), readioctx));
}
TEST_F(LibRadosSnapshotsSelfManagedPP, SnapOverlapPP) {
+ SKIP_IF_CRIMSON();
std::vector<uint64_t> my_snaps;
IoCtx readioctx;
ASSERT_EQ(0, cluster.ioctx_create(pool_name.c_str(), readioctx));
}
TEST_F(LibRadosSnapshotsSelfManagedPP, Bug11677) {
+ SKIP_IF_CRIMSON();
std::vector<uint64_t> my_snaps;
my_snaps.push_back(-2);
ASSERT_EQ(0, ioctx.selfmanaged_snap_create(&my_snaps.back()));
}
TEST_F(LibRadosSnapshotsSelfManagedPP, OrderSnap) {
+ SKIP_IF_CRIMSON();
std::vector<uint64_t> my_snaps;
char buf[bufsize];
memset(buf, 0xcc, sizeof(buf));
}
TEST_F(LibRadosSnapshotsSelfManagedPP, ReusePurgedSnap) {
+ SKIP_IF_CRIMSON();
std::vector<uint64_t> my_snaps;
my_snaps.push_back(-2);
ASSERT_EQ(0, ioctx.selfmanaged_snap_create(&my_snaps.back()));
// EC testing
TEST_F(LibRadosSnapshotsECPP, SnapListPP) {
+ SKIP_IF_CRIMSON();
char buf[bufsize];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl1;
}
TEST_F(LibRadosSnapshotsECPP, SnapRemovePP) {
+ SKIP_IF_CRIMSON();
char buf[bufsize];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl1;
}
TEST_F(LibRadosSnapshotsECPP, RollbackPP) {
+ SKIP_IF_CRIMSON();
char buf[bufsize];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl1;
}
TEST_F(LibRadosSnapshotsECPP, SnapGetNamePP) {
+ SKIP_IF_CRIMSON();
char buf[bufsize];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl;
}
TEST_F(LibRadosSnapshotsSelfManagedECPP, SnapPP) {
+ SKIP_IF_CRIMSON();
std::vector<uint64_t> my_snaps;
my_snaps.push_back(-2);
ASSERT_EQ(0, ioctx.selfmanaged_snap_create(&my_snaps.back()));
}
TEST_F(LibRadosSnapshotsSelfManagedECPP, RollbackPP) {
+ SKIP_IF_CRIMSON();
std::vector<uint64_t> my_snaps;
IoCtx readioctx;
ASSERT_EQ(0, cluster.ioctx_create(pool_name.c_str(), readioctx));
}
TEST_F(LibRadosSnapshotsSelfManagedECPP, Bug11677) {
+ SKIP_IF_CRIMSON();
std::vector<uint64_t> my_snaps;
my_snaps.push_back(-2);
ASSERT_EQ(0, ioctx.selfmanaged_snap_create(&my_snaps.back()));
#include <algorithm>
#include <errno.h>
#include "gtest/gtest.h"
+#include "crimson_utils.h"
typedef RadosTest LibRadosStat;
typedef RadosTestEC LibRadosStatEC;
}
TEST_F(LibRadosStatEC, Stat) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xcc, sizeof(buf));
ASSERT_EQ(0, rados_write(ioctx, "foo", buf, sizeof(buf), 0));
}
TEST_F(LibRadosStatEC, StatNS) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xcc, sizeof(buf));
rados_ioctx_set_namespace(ioctx, "");
}
TEST_F(LibRadosStatEC, ClusterStat) {
+ SKIP_IF_CRIMSON();
struct rados_cluster_stat_t result;
ASSERT_EQ(0, rados_cluster_stat(cluster, &result));
}
TEST_F(LibRadosStatEC, PoolStat) {
+ SKIP_IF_CRIMSON();
char buf[128];
char actual_pool_name[80];
unsigned l = rados_ioctx_get_pool_name(ioctx, actual_pool_name, sizeof(actual_pool_name));
#include "test/librados/test_cxx.h"
#include "test/librados/testcase_cxx.h"
+#include "crimson_utils.h"
using namespace librados;
}
TEST_F(LibRadosStatECPP, StatPP) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl;
}
TEST_F(LibRadosStatECPP, ClusterStatPP) {
+ SKIP_IF_CRIMSON();
cluster_stat_t cstat;
ASSERT_EQ(0, cluster.cluster_stat(cstat));
}
TEST_F(LibRadosStatECPP, PoolStatPP) {
+ SKIP_IF_CRIMSON();
std::string n = ioctx.get_pool_name();
ASSERT_EQ(n, pool_name);
char buf[128];
}
TEST_F(LibRadosStatECPP, StatPPNS) {
+ SKIP_IF_CRIMSON();
char buf[128];
memset(buf, 0xcc, sizeof(buf));
bufferlist bl;
#include "cls/cas/cls_cas_client.h"
#include "cls/cas/cls_cas_internal.h"
+#include "crimson_utils.h"
using namespace std;
using namespace librados;
std::string LibRadosTwoPoolsPP::cache_pool_name;
TEST_F(LibRadosTierPP, Dirty) {
+ SKIP_IF_CRIMSON();
{
ObjectWriteOperation op;
op.undirty();
}
TEST_F(LibRadosTwoPoolsPP, Overlay) {
+ SKIP_IF_CRIMSON();
// create objects
{
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsPP, Promote) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsPP, PromoteSnap) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsPP, PromoteSnapScrub) {
+ SKIP_IF_CRIMSON();
int num = 100;
// create objects
}
TEST_F(LibRadosTwoPoolsPP, PromoteSnapTrimRace) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsPP, Whiteout) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsPP, WhiteoutDeleteCreate) {
+ SKIP_IF_CRIMSON();
// configure cache
bufferlist inbl;
ASSERT_EQ(0, cluster.mon_command(
}
TEST_F(LibRadosTwoPoolsPP, Evict) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsPP, EvictSnap) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
// this test case reproduces http://tracker.ceph.com/issues/8629
TEST_F(LibRadosTwoPoolsPP, EvictSnap2) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
//This test case reproduces http://tracker.ceph.com/issues/17445
TEST_F(LibRadosTwoPoolsPP, ListSnap){
+ SKIP_IF_CRIMSON();
// Create object
{
bufferlist bl;
// This test case reproduces https://tracker.ceph.com/issues/49409
TEST_F(LibRadosTwoPoolsPP, EvictSnapRollbackReadRace) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsPP, TryFlush) {
+ SKIP_IF_CRIMSON();
// configure cache
bufferlist inbl;
ASSERT_EQ(0, cluster.mon_command(
}
TEST_F(LibRadosTwoPoolsPP, Flush) {
+ SKIP_IF_CRIMSON();
// configure cache
bufferlist inbl;
ASSERT_EQ(0, cluster.mon_command(
}
TEST_F(LibRadosTwoPoolsPP, FlushSnap) {
+ SKIP_IF_CRIMSON();
// configure cache
bufferlist inbl;
ASSERT_EQ(0, cluster.mon_command(
}
TEST_F(LibRadosTierPP, FlushWriteRaces) {
+ SKIP_IF_CRIMSON();
Rados cluster;
std::string pool_name = get_temp_pool_name();
std::string cache_pool_name = pool_name + "-cache";
}
TEST_F(LibRadosTwoPoolsPP, FlushTryFlushRaces) {
+ SKIP_IF_CRIMSON();
// configure cache
bufferlist inbl;
ASSERT_EQ(0, cluster.mon_command(
}
TEST_F(LibRadosTwoPoolsPP, TryFlushReadRace) {
+ SKIP_IF_CRIMSON();
// configure cache
bufferlist inbl;
ASSERT_EQ(0, cluster.mon_command(
}
TEST_F(LibRadosTierPP, HitSetNone) {
+ SKIP_IF_CRIMSON();
{
list< pair<time_t,time_t> > ls;
AioCompletion *c = librados::Rados::aio_create_completion();
}
TEST_F(LibRadosTwoPoolsPP, HitSetRead) {
+ SKIP_IF_CRIMSON();
// make it a tier
bufferlist inbl;
ASSERT_EQ(0, cluster.mon_command(
}
TEST_F(LibRadosTwoPoolsPP, HitSetWrite) {
+ SKIP_IF_CRIMSON();
int num_pg = _get_pg_num(cluster, pool_name);
ceph_assert(num_pg > 0);
}
TEST_F(LibRadosTwoPoolsPP, HitSetTrim) {
+ SKIP_IF_CRIMSON();
unsigned count = 3;
unsigned period = 3;
}
TEST_F(LibRadosTwoPoolsPP, PromoteOn2ndRead) {
+ SKIP_IF_CRIMSON();
// create object
for (int i=0; i<20; ++i) {
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsPP, ProxyRead) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsPP, CachePin) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsPP, SetRedirectRead) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsPP, ManifestPromoteRead) {
+ SKIP_IF_CRIMSON();
// skip test if not yet mimic
if (_get_required_osd_release(cluster) < "mimic") {
GTEST_SKIP() << "cluster is not yet mimic, skipping test";
}
TEST_F(LibRadosTwoPoolsPP, ManifestRefRead) {
+ SKIP_IF_CRIMSON();
// note: require >= mimic
// create object
}
TEST_F(LibRadosTwoPoolsPP, ManifestUnset) {
+ SKIP_IF_CRIMSON();
// skip test if not yet nautilus
if (_get_required_osd_release(cluster) < "nautilus") {
GTEST_SKIP() << "cluster is not yet nautilus, skipping test";
using ceph::crypto::SHA1;
#include "rgw/rgw_common.h"
TEST_F(LibRadosTwoPoolsPP, ManifestDedupRefRead) {
+ SKIP_IF_CRIMSON();
// skip test if not yet nautilus
if (_get_required_osd_release(cluster) < "nautilus") {
GTEST_SKIP() << "cluster is not yet nautilus, skipping test";
}
TEST_F(LibRadosTwoPoolsPP, ManifestSnapRefcount) {
+ SKIP_IF_CRIMSON();
// skip test if not yet octopus
if (_get_required_osd_release(cluster) < "octopus") {
cout << "cluster is not yet octopus, skipping test" << std::endl;
}
TEST_F(LibRadosTwoPoolsPP, ManifestSnapRefcount2) {
+ SKIP_IF_CRIMSON();
// skip test if not yet octopus
if (_get_required_osd_release(cluster) < "octopus") {
cout << "cluster is not yet octopus, skipping test" << std::endl;
}
TEST_F(LibRadosTwoPoolsPP, ManifestTestSnapCreate) {
+ SKIP_IF_CRIMSON();
// skip test if not yet octopus
if (_get_required_osd_release(cluster) < "octopus") {
GTEST_SKIP() << "cluster is not yet octopus, skipping test";
}
TEST_F(LibRadosTwoPoolsPP, ManifestRedirectAfterPromote) {
+ SKIP_IF_CRIMSON();
// skip test if not yet octopus
if (_get_required_osd_release(cluster) < "octopus") {
GTEST_SKIP() << "cluster is not yet octopus, skipping test";
}
TEST_F(LibRadosTwoPoolsPP, ManifestCheckRefcountWhenModification) {
+ SKIP_IF_CRIMSON();
// skip test if not yet octopus
if (_get_required_osd_release(cluster) < "octopus") {
GTEST_SKIP() << "cluster is not yet octopus, skipping test";
}
TEST_F(LibRadosTwoPoolsPP, ManifestSnapIncCount) {
+ SKIP_IF_CRIMSON();
// skip test if not yet octopus
if (_get_required_osd_release(cluster) < "octopus") {
cout << "cluster is not yet octopus, skipping test" << std::endl;
}
TEST_F(LibRadosTwoPoolsPP, ManifestEvict) {
+ SKIP_IF_CRIMSON();
// skip test if not yet octopus
if (_get_required_osd_release(cluster) < "octopus") {
cout << "cluster is not yet octopus, skipping test" << std::endl;
}
TEST_F(LibRadosTwoPoolsPP, ManifestEvictPromote) {
+ SKIP_IF_CRIMSON();
// skip test if not yet octopus
if (_get_required_osd_release(cluster) < "octopus") {
cout << "cluster is not yet octopus, skipping test" << std::endl;
TEST_F(LibRadosTwoPoolsPP, ManifestSnapSizeMismatch) {
+ SKIP_IF_CRIMSON();
// skip test if not yet octopus
if (_get_required_osd_release(cluster) < "octopus") {
cout << "cluster is not yet octopus, skipping test" << std::endl;
#include <common/CDC.h>
TEST_F(LibRadosTwoPoolsPP, DedupFlushRead) {
+ SKIP_IF_CRIMSON();
// skip test if not yet octopus
if (_get_required_osd_release(cluster) < "octopus") {
GTEST_SKIP() << "cluster is not yet octopus, skipping test";
}
TEST_F(LibRadosTwoPoolsPP, ManifestFlushSnap) {
+ SKIP_IF_CRIMSON();
// skip test if not yet octopus
if (_get_required_osd_release(cluster) < "octopus") {
cout << "cluster is not yet octopus, skipping test" << std::endl;
}
TEST_F(LibRadosTwoPoolsPP, ManifestFlushDupCount) {
+ SKIP_IF_CRIMSON();
// skip test if not yet octopus
if (_get_required_osd_release(cluster) < "octopus") {
cout << "cluster is not yet octopus, skipping test" << std::endl;
}
TEST_F(LibRadosTwoPoolsPP, TierFlushDuringFlush) {
+ SKIP_IF_CRIMSON();
// skip test if not yet octopus
if (_get_required_osd_release(cluster) < "octopus") {
cout << "cluster is not yet octopus, skipping test" << std::endl;
}
TEST_F(LibRadosTwoPoolsPP, ManifestSnapHasChunk) {
+ SKIP_IF_CRIMSON();
// skip test if not yet octopus
if (_get_required_osd_release(cluster) < "octopus") {
cout << "cluster is not yet octopus, skipping test" << std::endl;
}
TEST_F(LibRadosTwoPoolsPP, ManifestRollback) {
+ SKIP_IF_CRIMSON();
// skip test if not yet pacific
if (_get_required_osd_release(cluster) < "pacific") {
cout << "cluster is not yet pacific, skipping test" << std::endl;
}
TEST_F(LibRadosTwoPoolsPP, ManifestRollbackRefcount) {
+ SKIP_IF_CRIMSON();
// skip test if not yet pacific
if (_get_required_osd_release(cluster) < "pacific") {
cout << "cluster is not yet pacific, skipping test" << std::endl;
}
TEST_F(LibRadosTwoPoolsPP, ManifestEvictRollback) {
+ SKIP_IF_CRIMSON();
// skip test if not yet pacific
if (_get_required_osd_release(cluster) < "pacific") {
cout << "cluster is not yet pacific, skipping test" << std::endl;
std::string LibRadosTwoPoolsECPP::cache_pool_name;
TEST_F(LibRadosTierECPP, Dirty) {
+ SKIP_IF_CRIMSON();
{
ObjectWriteOperation op;
op.undirty();
}
TEST_F(LibRadosTwoPoolsECPP, Overlay) {
+ SKIP_IF_CRIMSON();
// create objects
{
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsECPP, Promote) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsECPP, PromoteSnap) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsECPP, PromoteSnapTrimRace) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsECPP, Whiteout) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsECPP, Evict) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsECPP, EvictSnap) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsECPP, TryFlush) {
+ SKIP_IF_CRIMSON();
// configure cache
bufferlist inbl;
ASSERT_EQ(0, cluster.mon_command(
}
TEST_F(LibRadosTwoPoolsECPP, FailedFlush) {
+ SKIP_IF_CRIMSON();
// configure cache
bufferlist inbl;
ASSERT_EQ(0, cluster.mon_command(
}
TEST_F(LibRadosTwoPoolsECPP, Flush) {
+ SKIP_IF_CRIMSON();
// configure cache
bufferlist inbl;
ASSERT_EQ(0, cluster.mon_command(
}
TEST_F(LibRadosTwoPoolsECPP, FlushSnap) {
+ SKIP_IF_CRIMSON();
// configure cache
bufferlist inbl;
ASSERT_EQ(0, cluster.mon_command(
}
TEST_F(LibRadosTierECPP, FlushWriteRaces) {
+ SKIP_IF_CRIMSON();
Rados cluster;
std::string pool_name = get_temp_pool_name();
std::string cache_pool_name = pool_name + "-cache";
}
TEST_F(LibRadosTwoPoolsECPP, FlushTryFlushRaces) {
+ SKIP_IF_CRIMSON();
// configure cache
bufferlist inbl;
ASSERT_EQ(0, cluster.mon_command(
}
TEST_F(LibRadosTwoPoolsECPP, TryFlushReadRace) {
+ SKIP_IF_CRIMSON();
// configure cache
bufferlist inbl;
ASSERT_EQ(0, cluster.mon_command(
}
TEST_F(LibRadosTierECPP, CallForcesPromote) {
+ SKIP_IF_CRIMSON();
Rados cluster;
std::string pool_name = get_temp_pool_name();
std::string cache_pool_name = pool_name + "-cache";
}
TEST_F(LibRadosTierECPP, HitSetNone) {
+ SKIP_IF_CRIMSON();
{
list< pair<time_t,time_t> > ls;
AioCompletion *c = librados::Rados::aio_create_completion();
}
TEST_F(LibRadosTwoPoolsECPP, HitSetRead) {
+ SKIP_IF_CRIMSON();
// make it a tier
bufferlist inbl;
ASSERT_EQ(0, cluster.mon_command(
#endif
TEST_F(LibRadosTwoPoolsECPP, HitSetTrim) {
+ SKIP_IF_CRIMSON();
unsigned count = 3;
unsigned period = 3;
}
TEST_F(LibRadosTwoPoolsECPP, PromoteOn2ndRead) {
+ SKIP_IF_CRIMSON();
// create object
for (int i=0; i<20; ++i) {
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsECPP, ProxyRead) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsECPP, CachePin) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
cluster.wait_for_latest_osdmap();
}
TEST_F(LibRadosTwoPoolsECPP, SetRedirectRead) {
+ SKIP_IF_CRIMSON();
// create object
{
bufferlist bl;
}
TEST_F(LibRadosTwoPoolsECPP, SetChunkRead) {
+ SKIP_IF_CRIMSON();
// note: require >= mimic
{
}
TEST_F(LibRadosTwoPoolsECPP, ManifestPromoteRead) {
+ SKIP_IF_CRIMSON();
// note: require >= mimic
// create object
}
TEST_F(LibRadosTwoPoolsECPP, TrySetDedupTier) {
+ SKIP_IF_CRIMSON();
// note: require >= mimic
bufferlist inbl;
}
TEST_F(LibRadosTwoPoolsPP, PropagateBaseTierError) {
+ SKIP_IF_CRIMSON();
// write object to base tier
bufferlist omap_bl;
encode(static_cast<uint32_t>(0U), omap_bl);
}
TEST_F(LibRadosTwoPoolsPP, HelloWriteReturn) {
+ SKIP_IF_CRIMSON();
// configure cache
bufferlist inbl;
ASSERT_EQ(0, cluster.mon_command(
}
TEST_F(LibRadosTwoPoolsPP, TierFlushDuringUnsetDedupTier) {
+ SKIP_IF_CRIMSON();
// skip test if not yet octopus
if (_get_required_osd_release(cluster) < "octopus") {
cout << "cluster is not yet octopus, skipping test" << std::endl;
#include "include/rados/rados_types.h"
#include "test/librados/test.h"
#include "test/librados/TestCase.h"
+#include "crimson_utils.h"
#include <errno.h>
#include <fcntl.h>
}
TEST_F(LibRadosWatchNotifyEC, WatchNotify) {
+ SKIP_IF_CRIMSON();
ASSERT_EQ(0, sem_init(&sem, 0, 0));
char buf[128];
memset(buf, 0xcc, sizeof(buf));
#include "include/rados/rados_types.h"
#include "test/librados/test_cxx.h"
#include "test/librados/testcase_cxx.h"
-
+#include "crimson_utils.h"
using namespace librados;
}
TEST_F(LibRadosWatchNotifyECPP, WatchNotify) {
+ SKIP_IF_CRIMSON();
ASSERT_EQ(0, sem_init(&sem, 0, 0));
char buf[128];
memset(buf, 0xcc, sizeof(buf));
}
TEST_F(LibRadosWatchNotifyECPP, WatchNotifyTimeout) {
+ SKIP_IF_CRIMSON();
ASSERT_EQ(0, sem_init(&sem, 0, 0));
ioctx.set_notify_timeout(1);
uint64_t handle;