1
0
mirror of https://github.com/pgbackrest/pgbackrest.git synced 2024-12-14 10:13:05 +02:00

Add TEST_RESULT_STR_Z_KEYRPL() test macro.

This macro will automatically do key replacement before the comparison. This saves the indentation required for an embedded function call.

Possibly TEST_RESULT_Z_KEYRPL() would also be useful but it will be added when needed.
This commit is contained in:
David Steele 2020-03-18 10:05:08 -04:00
parent f2548f45ce
commit b8cd1b6790

View File

@ -344,6 +344,8 @@ Macros to ease the use of common data types
TEST_RESULT_Z(strPtr(statement), strPtr(resultExpected), __VA_ARGS__);
#define TEST_RESULT_STR_Z(statement, resultExpected, ...) \
TEST_RESULT_Z(strPtr(statement), resultExpected, __VA_ARGS__);
#define TEST_RESULT_STR_Z_KEYRPL(statement, resultExpected, ...) \
TEST_RESULT_Z(strPtr(statement), hrnReplaceKey(resultExpected), __VA_ARGS__);
#define TEST_RESULT_Z_STR(statement, resultExpected, ...) \
TEST_RESULT_Z(statement, strPtr(resultExpected), __VA_ARGS__);