1
0
mirror of https://github.com/meekrosoft/fff synced 2026-01-23 08:25:59 +01:00

Added test case for FAKE_VALUE_FUNC_VARARG.

This commit is contained in:
Rubio R. C. Terra
2016-06-07 09:45:40 -03:00
committed by Rubio Ribeiro Canario Terra
parent 8c7bd6912f
commit 88864216d3
5 changed files with 20 additions and 4 deletions

View File

@@ -27,7 +27,8 @@ FAKE_VOID_FUNC(voidfunc2, char, char);
FAKE_VALUE_FUNC(long, longfunc0);
FAKE_VALUE_FUNC(enum MYBOOL, enumfunc0);
FAKE_VALUE_FUNC(struct MyStruct, structfunc0);
FAKE_VOID_FUNC3_VARARG(voidfunc3var, char *, int, ...);
FAKE_VOID_FUNC_VARARG(voidfunc3var, char *, int, ...);
FAKE_VALUE_FUNC_VARARG(int, valuefunc3var, char *, int, ...);
FAKE_VALUE_FUNC(int, strlcpy3, char* const, const char* const, const size_t);
FAKE_VOID_FUNC(voidfunc20, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int);
@@ -39,6 +40,7 @@ void setup()
RESET_FAKE(enumfunc0);
RESET_FAKE(structfunc0);
RESET_FAKE(voidfunc3var);
RESET_FAKE(valuefunc3var);
RESET_FAKE(strlcpy3);
FFF_RESET_HISTORY();
}
@@ -96,7 +98,8 @@ int main()
RUN_TEST(FFFTestSuite, can_register_custom_fake);
RUN_TEST(FFFTestSuite, when_value_custom_fake_called_THEN_it_returns_custom_return_value);
RUN_TEST(FFFTestSuite, use_vararg_fake_with_different_number_of_arguments);
RUN_TEST(FFFTestSuite, use_void_vararg_fake_with_different_number_of_arguments);
RUN_TEST(FFFTestSuite, use_value_vararg_fake_with_different_number_of_arguments);
RUN_TEST(FFFTestSuite, can_capture_upto_20_arguments_correctly);