|
38 | 38 | #include "mock_msg.h" |
39 | 39 |
|
40 | 40 | void |
41 | | -__wrap_add_option(struct options *options, char *p[], bool is_inline, const char *file, |
42 | | - int line, const int level, const msglvl_t msglevel, |
43 | | - const unsigned int permission_mask, unsigned int *option_types_found, |
44 | | - struct env_set *es) |
| 41 | +add_option(struct options *options, char *p[], bool is_inline, const char *file, |
| 42 | + int line, const int level, const msglvl_t msglevel, |
| 43 | + const unsigned int permission_mask, unsigned int *option_types_found, |
| 44 | + struct env_set *es) |
45 | 45 | { |
46 | 46 | function_called(); |
47 | 47 | check_expected(p); |
48 | 48 | check_expected(is_inline); |
49 | 49 | } |
50 | 50 |
|
51 | 51 | void |
52 | | -__wrap_remove_option(struct context *c, struct options *options, char *p[], bool is_inline, |
53 | | - const char *file, int line, const msglvl_t msglevel, |
54 | | - const unsigned int permission_mask, unsigned int *option_types_found, |
55 | | - struct env_set *es) |
| 52 | +remove_option(struct context *c, struct options *options, char *p[], bool is_inline, |
| 53 | + const char *file, int line, const msglvl_t msglevel, |
| 54 | + const unsigned int permission_mask, unsigned int *option_types_found, |
| 55 | + struct env_set *es) |
56 | 56 | { |
57 | 57 | } |
58 | 58 |
|
59 | 59 | void |
60 | | -__wrap_update_option(struct context *c, struct options *options, char *p[], bool is_inline, |
61 | | - const char *file, int line, const int level, const msglvl_t msglevel, |
62 | | - const unsigned int permission_mask, unsigned int *option_types_found, |
63 | | - struct env_set *es, unsigned int *update_options_found) |
| 60 | +update_option(struct context *c, struct options *options, char *p[], bool is_inline, |
| 61 | + const char *file, int line, const int level, const msglvl_t msglevel, |
| 62 | + const unsigned int permission_mask, unsigned int *option_types_found, |
| 63 | + struct env_set *es, unsigned int *update_options_found) |
64 | 64 | { |
65 | 65 | } |
66 | 66 |
|
67 | 67 | void |
68 | | -__wrap_usage(void) |
| 68 | +usage(void) |
69 | 69 | { |
70 | 70 | } |
71 | 71 |
|
@@ -270,34 +270,34 @@ test_read_config(void **state) |
270 | 270 | p_expect_inlineopt[1] = "some text\nother text\n"; |
271 | 271 |
|
272 | 272 | /* basic test */ |
273 | | - expect_function_call(__wrap_add_option); |
274 | | - expect_check(__wrap_add_option, p, check_tokens, p_expect_someopt); |
275 | | - expect_value(__wrap_add_option, is_inline, 0); |
276 | | - expect_function_call(__wrap_add_option); |
277 | | - expect_check(__wrap_add_option, p, check_tokens, p_expect_otheropt); |
278 | | - expect_value(__wrap_add_option, is_inline, 0); |
| 273 | + expect_function_call(add_option); |
| 274 | + expect_check(add_option, p, check_tokens, p_expect_someopt); |
| 275 | + expect_value(add_option, is_inline, 0); |
| 276 | + expect_function_call(add_option); |
| 277 | + expect_check(add_option, p, check_tokens, p_expect_otheropt); |
| 278 | + expect_value(add_option, is_inline, 0); |
279 | 279 | read_single_config(&o, "someopt parm1 parm2\n otheropt 1 2"); |
280 | 280 |
|
281 | 281 | /* -- gets stripped */ |
282 | | - expect_function_call(__wrap_add_option); |
283 | | - expect_check(__wrap_add_option, p, check_tokens, p_expect_someopt); |
284 | | - expect_value(__wrap_add_option, is_inline, 0); |
285 | | - expect_function_call(__wrap_add_option); |
286 | | - expect_check(__wrap_add_option, p, check_tokens, p_expect_otheropt); |
287 | | - expect_value(__wrap_add_option, is_inline, 0); |
| 282 | + expect_function_call(add_option); |
| 283 | + expect_check(add_option, p, check_tokens, p_expect_someopt); |
| 284 | + expect_value(add_option, is_inline, 0); |
| 285 | + expect_function_call(add_option); |
| 286 | + expect_check(add_option, p, check_tokens, p_expect_otheropt); |
| 287 | + expect_value(add_option, is_inline, 0); |
288 | 288 | read_single_config(&o, "someopt parm1 parm2\n\t--otheropt 1 2"); |
289 | 289 |
|
290 | 290 | /* inline options */ |
291 | | - expect_function_call(__wrap_add_option); |
292 | | - expect_check(__wrap_add_option, p, check_tokens, p_expect_inlineopt); |
293 | | - expect_value(__wrap_add_option, is_inline, 1); |
| 291 | + expect_function_call(add_option); |
| 292 | + expect_check(add_option, p, check_tokens, p_expect_inlineopt); |
| 293 | + expect_value(add_option, is_inline, 1); |
294 | 294 | read_single_config(&o, "<inlineopt>\nsome text\nother text\n</inlineopt>"); |
295 | 295 |
|
296 | 296 | p_expect_inlineopt[0] = "inlineopt"; |
297 | 297 | p_expect_inlineopt[1] = A_TIMES_256 A_TIMES_256 A_TIMES_256 A_TIMES_256 A_TIMES_256 "\n"; |
298 | | - expect_function_call(__wrap_add_option); |
299 | | - expect_check(__wrap_add_option, p, check_tokens, p_expect_inlineopt); |
300 | | - expect_value(__wrap_add_option, is_inline, 1); |
| 298 | + expect_function_call(add_option); |
| 299 | + expect_check(add_option, p, check_tokens, p_expect_inlineopt); |
| 300 | + expect_value(add_option, is_inline, 1); |
301 | 301 | read_single_config(&o, "<inlineopt>\n" A_TIMES_256 A_TIMES_256 A_TIMES_256 A_TIMES_256 A_TIMES_256 "\n</inlineopt>"); |
302 | 302 |
|
303 | 303 | gc_free(&o.gc); |
|
0 commit comments