|
@@ 252-271 (lines=20) @@
|
| 249 |
|
assert status.OK() |
| 250 |
|
assert config_value == '2GB' |
| 251 |
|
|
| 252 |
|
@pytest.mark.level(2) |
| 253 |
|
def test_set_insert_buffer_size_valid_multiple_times(self, connect, collection): |
| 254 |
|
''' |
| 255 |
|
target: set insert_buffer_size |
| 256 |
|
method: call get_config correctly and repeatedly |
| 257 |
|
expected: status ok |
| 258 |
|
''' |
| 259 |
|
self.reset_configs(connect) |
| 260 |
|
for i in range(20): |
| 261 |
|
status, reply = connect.set_config("cache", "insert_buffer_size", '1GB') |
| 262 |
|
assert status.OK() |
| 263 |
|
status, config_value = connect.get_config("cache", "insert_buffer_size") |
| 264 |
|
assert status.OK() |
| 265 |
|
assert config_value == '1GB' |
| 266 |
|
for i in range(20): |
| 267 |
|
status, reply = connect.set_config("cache", "insert_buffer_size", '2GB') |
| 268 |
|
assert status.OK() |
| 269 |
|
status, config_value = connect.get_config("cache", "insert_buffer_size") |
| 270 |
|
assert status.OK() |
| 271 |
|
assert config_value == '2GB' |
| 272 |
|
|
| 273 |
|
@pytest.mark.timeout(CONFIG_TIMEOUT) |
| 274 |
|
def test_set_cache_out_of_memory_value_A(self, connect, collection): |
|
@@ 203-222 (lines=20) @@
|
| 200 |
|
assert status.OK() |
| 201 |
|
assert config_value == '2GB' |
| 202 |
|
|
| 203 |
|
@pytest.mark.level(2) |
| 204 |
|
def test_set_cache_size_valid_multiple_times(self, connect, collection): |
| 205 |
|
''' |
| 206 |
|
target: set cache_size |
| 207 |
|
method: call set_config correctly and repeatedly |
| 208 |
|
expected: status ok |
| 209 |
|
''' |
| 210 |
|
self.reset_configs(connect) |
| 211 |
|
for i in range(20): |
| 212 |
|
status, reply = connect.set_config("cache", "cache_size", '4GB') |
| 213 |
|
assert status.OK() |
| 214 |
|
status, config_value = connect.get_config("cache", "cache_size") |
| 215 |
|
assert status.OK() |
| 216 |
|
assert config_value == '4GB' |
| 217 |
|
for i in range(20): |
| 218 |
|
status, reply = connect.set_config("cache", "cache_size", '2GB') |
| 219 |
|
assert status.OK() |
| 220 |
|
status, config_value = connect.get_config("cache", "cache_size") |
| 221 |
|
assert status.OK() |
| 222 |
|
assert config_value == '2GB' |
| 223 |
|
|
| 224 |
|
@pytest.mark.level(2) |
| 225 |
|
def test_set_insert_buffer_size_invalid_parent_key(self, connect, collection): |