diff options
author | Amitay Isaacs <amitay@gmail.com> | 2017-06-14 16:24:02 +1000 |
---|---|---|
committer | Martin Schwenke <martins@samba.org> | 2017-06-26 15:47:24 +0200 |
commit | 339b818e56c143a7125491c6394677b0e2069d98 (patch) | |
tree | 886ff500f65703a7019465b9285704c04a82a2b2 /ctdb/tests | |
parent | 0b607528ff87c6953c02fd057a2b26815f154d88 (diff) | |
download | samba-339b818e56c143a7125491c6394677b0e2069d98.tar.gz |
ctdb-protocol: Add protocol marshalling for control DB_OPEN_FLAGS
Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Martin Schwenke <martin@meltin.net>
Diffstat (limited to 'ctdb/tests')
-rwxr-xr-x | ctdb/tests/cunit/protocol_test_002.sh | 2 | ||||
-rw-r--r-- | ctdb/tests/src/protocol_client_test.c | 18 |
2 files changed, 18 insertions, 2 deletions
diff --git a/ctdb/tests/cunit/protocol_test_002.sh b/ctdb/tests/cunit/protocol_test_002.sh index 929ff658718..0a3890eb24d 100755 --- a/ctdb/tests/cunit/protocol_test_002.sh +++ b/ctdb/tests/cunit/protocol_test_002.sh @@ -2,7 +2,7 @@ . "${TEST_SCRIPTS_DIR}/unit.sh" -last_control=148 +last_control=149 control_output=$( for i in $(seq 0 $last_control) ; do diff --git a/ctdb/tests/src/protocol_client_test.c b/ctdb/tests/src/protocol_client_test.c index c530dec72e8..48c0744151d 100644 --- a/ctdb/tests/src/protocol_client_test.c +++ b/ctdb/tests/src/protocol_client_test.c @@ -592,6 +592,10 @@ static void fill_ctdb_req_control_data(TALLOC_CTX *mem_ctx, cd->data.db_id = rand32(); break; + case CTDB_CONTROL_DB_OPEN_FLAGS: + cd->data.db_id = rand32(); + break; + } } @@ -988,6 +992,10 @@ static void verify_ctdb_req_control_data(struct ctdb_req_control_data *cd, assert(cd->data.db_id == cd2->data.db_id); break; + case CTDB_CONTROL_DB_OPEN_FLAGS: + assert(cd->data.db_id == cd2->data.db_id); + break; + } } @@ -1395,6 +1403,10 @@ static void fill_ctdb_reply_control_data(TALLOC_CTX *mem_ctx, cd->data.num_records = rand32(); break; + case CTDB_CONTROL_DB_OPEN_FLAGS: + cd->data.tdb_flags = rand32(); + break; + } } @@ -1732,6 +1744,10 @@ static void verify_ctdb_reply_control_data(struct ctdb_reply_control_data *cd, assert(cd->data.num_records == cd2->data.num_records); break; + case CTDB_CONTROL_DB_OPEN_FLAGS: + assert(cd->data.tdb_flags == cd2->data.tdb_flags); + break; + } } @@ -2174,7 +2190,7 @@ static void test_ctdb_reply_dmaster(void) talloc_free(mem_ctx); } -#define NUM_CONTROLS 149 +#define NUM_CONTROLS 150 static void test_ctdb_req_control_data(void) { |