|
79 | 79 | return; \ |
80 | 80 | } |
81 | 81 |
|
82 | | -#define SKIP_TEST_MESSAGE(server_version_string, comparison, version_string) \ |
| 82 | +#define SERVER_VERSION_SKIP_TEST_MESSAGE(server_version_string, comparison, version_string) \ |
83 | 83 | "Unsupported for Apache Cassandra Version " << server_version_string << ": Server version is " \ |
84 | 84 | << comparison << " the specified version " << version_string |
85 | 85 |
|
| 86 | +#define PROTOCOL_VERSION_SKIP_TEST_MESSAGE(server_version_string, comparison, version_string) \ |
| 87 | + "Unsupported for Apache Cassandra protocol version " << server_version_string << ": Server version is " \ |
| 88 | + << comparison << " the specified protocol version " << version_string |
| 89 | + |
86 | 90 | /* Maintain existing behaviour; default message indicates server < specified */ |
87 | 91 | #define SKIP_TEST_VERSION(server_version_string, version_string) \ |
88 | | - SKIP_TEST(SKIP_TEST_MESSAGE(server_version_string, '<', version_string)) |
| 92 | + SKIP_TEST(SERVER_VERSION_SKIP_TEST_MESSAGE(server_version_string, '<', version_string)) |
89 | 93 |
|
90 | 94 | #define CHECK_VERSION(version) \ |
91 | 95 | do { \ |
|
114 | 118 | if (!Options::is_cassandra()) { \ |
115 | 119 | cass_version = static_cast<CCM::DseVersion>(cass_version).get_cass_version(); \ |
116 | 120 | } \ |
117 | | - std::vector<std::string> versions = Utils::explode(version_string,','); \ |
| 121 | + std::vector<std::string> versions = Utils::explode(version_string,','); \ |
118 | 122 | for (unsigned int i = 0; i < versions.size(); i++) { \ |
119 | 123 | CCM::CassVersion version = CCM::CassVersion(versions[i]); \ |
120 | 124 | if (cass_version.major_version == version.major_version && \ |
121 | 125 | cass_version.minor_version == version.minor_version && \ |
122 | 126 | cass_version.patch_version >= version.patch_version) { \ |
123 | 127 | SKIP_TEST( \ |
124 | | - SKIP_TEST_MESSAGE( \ |
| 128 | + SERVER_VERSION_SKIP_TEST_MESSAGE( \ |
125 | 129 | cass_version.to_string(), ">=", version.to_string())) \ |
126 | 130 | } \ |
127 | 131 | } \ |
128 | 132 | } while (0) |
129 | 133 |
|
130 | | -#define CHECK_PROTOCOL_VERSION(version) \ |
131 | | - do { \ |
132 | | - int proto_version = this->protocol_version_; \ |
133 | | - if (proto_version < version) { \ |
134 | | - SKIP_TEST_VERSION(std::to_string(proto_version), #version) \ |
135 | | - } \ |
| 134 | +#define CHECK_PROTOCOL_VERSION(version) \ |
| 135 | + do { \ |
| 136 | + int proto_version = this->protocol_version_; \ |
| 137 | + if (proto_version < version) { \ |
| 138 | + SKIP_TEST( \ |
| 139 | + PROTOCOL_VERSION_SKIP_TEST_MESSAGE( \ |
| 140 | + proto_version, '<', version)); \ |
| 141 | + } \ |
136 | 142 | } while (0) |
137 | 143 |
|
138 | 144 | #define CHECK_OPTIONS_VERSION(version) \ |
@@ -343,13 +349,6 @@ class Integration : public testing::Test { |
343 | 349 | * destroyed |
344 | 350 | */ |
345 | 351 | bool is_test_chaotic_; |
346 | | - /** |
347 | | - * Flag to indicate if the beta protocol should be enabled. True if beta |
348 | | - * protocol should be enabled (Cassandra must be >= v3.10.0); false |
349 | | - * otherwise. |
350 | | - * (DEFAULT: true) |
351 | | - */ |
352 | | - bool is_beta_protocol_; |
353 | 352 | /** |
354 | 353 | * Workload to apply to the cluster |
355 | 354 | */ |
|
0 commit comments