/* protocol types tests Copyright (C) Amitay Isaacs 2015-2017 This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, see . */ #include #include "protocol/protocol_basic.c" #include "tests/src/protocol_common_basic.h" PROTOCOL_TYPE1_TEST(uint8_t, ctdb_uint8); PROTOCOL_TYPE1_TEST(uint16_t, ctdb_uint16); PROTOCOL_TYPE1_TEST(int32_t, ctdb_int32); PROTOCOL_TYPE1_TEST(uint32_t, ctdb_uint32); PROTOCOL_TYPE1_TEST(uint64_t, ctdb_uint64); PROTOCOL_TYPE1_TEST(double, ctdb_double); PROTOCOL_TYPE1_TEST(bool, ctdb_bool); static void test_ctdb_chararray(void) { size_t len = rand_int(1000) + 1; char p1[len], p2[len]; size_t buflen, np = 0; size_t i; int ret; for (i=0; i