From 6cd355418c0e8a9254bb26c0fc5ec996acfc3337 Mon Sep 17 00:00:00 2001 From: Kevin Day Date: Sat, 28 May 2022 22:29:56 -0500 Subject: [PATCH] Cleanup: Remove the parameter checking macros around the function definitions in the unit test. The tests do not really matter when it comes to file size. Simplify the test code by not using these macros. These macros are still used to perform the call. They just do not need to be around the function definitions. --- .../f_account/tests/unit/c/test-account-by_id.c | 12 +++---- .../f_account/tests/unit/c/test-account-by_id.h | 4 +-- .../f_account/tests/unit/c/test-account-by_name.c | 14 ++++---- .../f_account/tests/unit/c/test-account-by_name.h | 4 +-- .../tests/unit/c/test-account-group_id_by_name.c | 14 ++++---- .../tests/unit/c/test-account-group_id_by_name.h | 4 +-- .../tests/unit/c/test-account-group_name_by_id.c | 12 +++---- .../tests/unit/c/test-account-group_name_by_id.h | 4 +-- .../tests/unit/c/test-account-id_by_name.c | 14 ++++---- .../tests/unit/c/test-account-id_by_name.h | 4 +-- .../tests/unit/c/test-account-name_by_id.c | 12 +++---- .../tests/unit/c/test-account-name_by_id.h | 4 +-- .../tests/unit/c/test-capability-ambient_get.c | 14 ++++---- .../tests/unit/c/test-capability-ambient_get.h | 4 +-- .../tests/unit/c/test-capability-clear.c | 12 +++---- .../tests/unit/c/test-capability-clear.h | 4 +-- .../tests/unit/c/test-capability-clear_flag.c | 2 +- .../tests/unit/c/test-capability-clear_flag.h | 4 +-- .../tests/unit/c/test-capability-copy.c | 14 ++++---- .../tests/unit/c/test-capability-copy.h | 4 +-- .../tests/unit/c/test-capability-copy_external.c | 14 ++++---- .../tests/unit/c/test-capability-copy_external.h | 4 +-- .../tests/unit/c/test-capability-copy_internal.c | 26 +++++++------- .../tests/unit/c/test-capability-copy_internal.h | 4 +-- .../tests/unit/c/test-capability-delete.c | 12 +++---- .../tests/unit/c/test-capability-delete.h | 4 +-- .../unit/c/test-capability-file_descriptor_get.c | 14 ++++---- .../unit/c/test-capability-file_descriptor_get.h | 4 +-- .../tests/unit/c/test-capability-file_get.c | 12 +++---- .../tests/unit/c/test-capability-file_get.h | 4 +-- .../tests/unit/c/test-capability-flag_get.c | 18 +++++----- .../tests/unit/c/test-capability-flag_get.h | 4 +-- .../tests/unit/c/test-capability-flag_set.c | 18 +++++----- .../tests/unit/c/test-capability-flag_set.h | 4 +-- .../tests/unit/c/test-capability-from_name.c | 14 ++++---- .../tests/unit/c/test-capability-from_name.h | 4 +-- .../tests/unit/c/test-capability-from_text.c | 14 ++++---- .../tests/unit/c/test-capability-from_text.h | 4 +-- .../tests/unit/c/test-capability-initialize.c | 12 +++---- .../tests/unit/c/test-capability-initialize.h | 4 +-- .../tests/unit/c/test-capability-mode_get.c | 12 +++---- .../tests/unit/c/test-capability-mode_get.h | 4 +-- .../tests/unit/c/test-capability-mode_get_name.c | 14 ++++---- .../tests/unit/c/test-capability-mode_get_name.h | 4 +-- .../tests/unit/c/test-capability-owner_get.c | 14 ++++---- .../tests/unit/c/test-capability-owner_get.h | 4 +-- .../unit/c/test-capability-process_bound_drop.c | 14 ++++---- .../unit/c/test-capability-process_bound_drop.h | 4 +-- .../unit/c/test-capability-process_bound_get.c | 14 ++++---- .../unit/c/test-capability-process_bound_get.h | 4 +-- .../tests/unit/c/test-capability-process_get.c | 12 +++---- .../tests/unit/c/test-capability-process_get.h | 4 +-- .../unit/c/test-capability-process_get_by_id.c | 12 +++---- .../unit/c/test-capability-process_get_by_id.h | 4 +-- .../unit/c/test-capability-security_bits_get.c | 12 +++---- .../unit/c/test-capability-security_bits_get.h | 4 +-- .../tests/unit/c/test-capability-size.c | 14 ++++---- .../tests/unit/c/test-capability-size.h | 4 +-- .../tests/unit/c/test-capability-to_name.c | 14 ++++---- .../tests/unit/c/test-capability-to_name.h | 4 +-- .../tests/unit/c/test-capability-to_text.c | 14 ++++---- .../tests/unit/c/test-capability-to_text.h | 4 +-- .../f_capability/tests/unit/c/test-capability.c | 6 ---- .../tests/unit/c/test-color-context_delete.c | 12 +++---- .../tests/unit/c/test-color-context_delete.h | 4 +-- .../tests/unit/c/test-color-context_destroy.c | 12 +++---- .../tests/unit/c/test-color-context_destroy.h | 4 +-- .../f_color/tests/unit/c/test-color-load_context.c | 12 +++---- .../f_color/tests/unit/c/test-color-load_context.h | 4 +-- level_0/f_color/tests/unit/c/test-color-save_1.c | 16 ++++----- level_0/f_color/tests/unit/c/test-color-save_1.h | 4 +-- level_0/f_color/tests/unit/c/test-color-save_2.c | 16 ++++----- level_0/f_color/tests/unit/c/test-color-save_2.h | 4 +-- level_0/f_color/tests/unit/c/test-color-save_3.c | 16 ++++----- level_0/f_color/tests/unit/c/test-color-save_3.h | 4 +-- level_0/f_color/tests/unit/c/test-color-save_4.c | 16 ++++----- level_0/f_color/tests/unit/c/test-color-save_4.h | 4 +-- level_0/f_color/tests/unit/c/test-color-save_5.c | 16 ++++----- level_0/f_color/tests/unit/c/test-color-save_5.h | 4 +-- level_0/f_color/tests/unit/c/test-color.c | 6 ---- .../unit/c/test-console-environment_process.c | 14 ++++---- .../unit/c/test-console-environment_process.h | 4 +-- .../f_console/tests/unit/c/test-console-identify.c | 14 ++++---- .../f_console/tests/unit/c/test-console-identify.h | 4 +-- .../c/test-console-parameter_prioritize_left.c | 32 ++++++++--------- .../c/test-console-parameter_prioritize_left.h | 4 +-- .../c/test-console-parameter_prioritize_right.c | 32 ++++++++--------- .../c/test-console-parameter_prioritize_right.h | 4 +-- .../tests/unit/c/test-console-parameter_process.c | 14 ++++---- .../tests/unit/c/test-console-parameter_process.h | 4 +-- .../tests/unit/c/test-console-parameters_delete.c | 12 +++---- .../tests/unit/c/test-console-parameters_delete.h | 4 +-- .../tests/unit/c/test-console-parameters_destroy.c | 12 +++---- .../tests/unit/c/test-console-parameters_destroy.h | 4 +-- level_0/f_console/tests/unit/c/test-console.c | 3 -- .../tests/unit/c/test-control_group-copy.c | 14 ++++---- .../tests/unit/c/test-control_group-copy.h | 4 +-- .../tests/unit/c/test-control_group.c | 1 - .../unit/c/test-conversion-character_to_binary.c | 12 +++---- .../unit/c/test-conversion-character_to_binary.h | 4 +-- .../unit/c/test-conversion-character_to_decimal.c | 12 +++---- .../unit/c/test-conversion-character_to_decimal.h | 4 +-- .../c/test-conversion-character_to_duodecimal.c | 12 +++---- .../c/test-conversion-character_to_duodecimal.h | 4 +-- .../c/test-conversion-character_to_hexidecimal.c | 12 +++---- .../c/test-conversion-character_to_hexidecimal.h | 4 +-- .../unit/c/test-conversion-character_to_octal.c | 12 +++---- .../unit/c/test-conversion-character_to_octal.h | 4 +-- .../unit/c/test-conversion-number_signed_print.c | 26 +++++++------- .../unit/c/test-conversion-number_signed_print.h | 4 +-- .../c/test-conversion-number_signed_to_string.c | 26 +++++++------- .../c/test-conversion-number_signed_to_string.h | 4 +-- .../unit/c/test-conversion-number_unsigned_print.c | 26 +++++++------- .../unit/c/test-conversion-number_unsigned_print.h | 4 +-- .../c/test-conversion-number_unsigned_to_string.c | 26 +++++++------- .../c/test-conversion-number_unsigned_to_string.h | 4 +-- .../f_conversion/tests/unit/c/test-conversion.c | 7 ---- .../f_directory/tests/unit/c/test-directory-list.c | 14 ++++---- .../f_directory/tests/unit/c/test-directory-list.h | 4 +-- .../f_directory/tests/unit/c/test-directory-open.c | 14 ++++---- .../f_directory/tests/unit/c/test-directory-open.h | 4 +-- .../tests/unit/c/test-directory-open_at.c | 14 ++++---- .../tests/unit/c/test-directory-open_at.h | 4 +-- .../tests/unit/c/test-directory-remove.c | 14 ++++---- .../tests/unit/c/test-directory-remove.h | 4 +-- .../tests/unit/c/test-directory-remove_custom.c | 14 ++++---- .../tests/unit/c/test-directory-remove_custom.h | 4 +-- .../tests/unit/c/test-environment-get.c | 14 ++++---- .../tests/unit/c/test-environment-get.h | 4 +-- level_0/f_file/tests/unit/c/test-file-close.c | 12 +++---- level_0/f_file/tests/unit/c/test-file-close.h | 4 +-- .../f_file/tests/unit/c/test-file-close_flush.c | 12 +++---- .../f_file/tests/unit/c/test-file-close_flush.h | 4 +-- level_0/f_file/tests/unit/c/test-file-descriptor.c | 12 +++---- level_0/f_file/tests/unit/c/test-file-descriptor.h | 4 +-- level_0/f_file/tests/unit/c/test-file-group_read.c | 12 +++---- level_0/f_file/tests/unit/c/test-file-group_read.h | 4 +-- level_0/f_file/tests/unit/c/test-file-link_read.c | 22 ++++++------ level_0/f_file/tests/unit/c/test-file-link_read.h | 4 +-- .../f_file/tests/unit/c/test-file-link_read_at.c | 18 +++++----- .../f_file/tests/unit/c/test-file-link_read_at.h | 4 +-- .../f_file/tests/unit/c/test-file-mode_determine.c | 16 ++++----- .../f_file/tests/unit/c/test-file-mode_determine.h | 4 +-- .../tests/unit/c/test-file-mode_from_string.c | 32 ++++++++--------- .../tests/unit/c/test-file-mode_from_string.h | 4 +-- level_0/f_file/tests/unit/c/test-file-mode_read.c | 12 +++---- level_0/f_file/tests/unit/c/test-file-mode_read.h | 4 +-- .../f_file/tests/unit/c/test-file-mode_read_at.c | 12 +++---- .../f_file/tests/unit/c/test-file-mode_read_at.h | 4 +-- .../f_file/tests/unit/c/test-file-mode_to_mode.c | 14 ++++---- .../f_file/tests/unit/c/test-file-mode_to_mode.h | 4 +-- level_0/f_file/tests/unit/c/test-file-name_base.c | 12 +++---- level_0/f_file/tests/unit/c/test-file-name_base.h | 4 +-- .../f_file/tests/unit/c/test-file-name_directory.c | 12 +++---- .../f_file/tests/unit/c/test-file-name_directory.h | 4 +-- level_0/f_file/tests/unit/c/test-file-open.c | 14 ++++---- level_0/f_file/tests/unit/c/test-file-open.h | 4 +-- level_0/f_file/tests/unit/c/test-file-open_at.c | 12 +++---- level_0/f_file/tests/unit/c/test-file-open_at.h | 4 +-- level_0/f_file/tests/unit/c/test-file-owner_read.c | 12 +++---- level_0/f_file/tests/unit/c/test-file-owner_read.h | 4 +-- level_0/f_file/tests/unit/c/test-file-read.c | 42 +++++++++++----------- level_0/f_file/tests/unit/c/test-file-read.h | 4 +-- level_0/f_file/tests/unit/c/test-file-read_block.c | 42 +++++++++++----------- level_0/f_file/tests/unit/c/test-file-read_block.h | 4 +-- level_0/f_file/tests/unit/c/test-file-read_until.c | 42 +++++++++++----------- level_0/f_file/tests/unit/c/test-file-read_until.h | 4 +-- level_0/f_file/tests/unit/c/test-file-seek.c | 30 ++++++++-------- level_0/f_file/tests/unit/c/test-file-seek.h | 4 +-- level_0/f_file/tests/unit/c/test-file-size.c | 12 +++---- level_0/f_file/tests/unit/c/test-file-size.h | 4 +-- level_0/f_file/tests/unit/c/test-file-size_at.c | 12 +++---- level_0/f_file/tests/unit/c/test-file-size_at.h | 4 +-- level_0/f_file/tests/unit/c/test-file-size_by_id.c | 12 +++---- level_0/f_file/tests/unit/c/test-file-size_by_id.h | 4 +-- level_0/f_file/tests/unit/c/test-file-stat.c | 12 +++---- level_0/f_file/tests/unit/c/test-file-stat.h | 4 +-- level_0/f_file/tests/unit/c/test-file-stat_at.c | 12 +++---- level_0/f_file/tests/unit/c/test-file-stat_at.h | 4 +-- level_0/f_file/tests/unit/c/test-file-stat_by_id.c | 12 +++---- level_0/f_file/tests/unit/c/test-file-stat_by_id.h | 4 +-- .../f_file/tests/unit/c/test-file-stream_close.c | 12 +++---- .../f_file/tests/unit/c/test-file-stream_close.h | 4 +-- .../f_file/tests/unit/c/test-file-stream_open.c | 12 +++---- .../f_file/tests/unit/c/test-file-stream_open.h | 4 +-- .../unit/c/test-file-stream_open_descriptor.c | 12 +++---- .../unit/c/test-file-stream_open_descriptor.h | 4 +-- .../f_file/tests/unit/c/test-file-stream_read.c | 34 +++++++++--------- .../f_file/tests/unit/c/test-file-stream_read.h | 4 +-- .../tests/unit/c/test-file-stream_read_block.c | 34 +++++++++--------- .../tests/unit/c/test-file-stream_read_block.h | 4 +-- .../tests/unit/c/test-file-stream_read_until.c | 32 ++++++++--------- .../tests/unit/c/test-file-stream_read_until.h | 4 +-- .../f_file/tests/unit/c/test-file-stream_reopen.c | 12 +++---- .../f_file/tests/unit/c/test-file-stream_reopen.h | 4 +-- .../f_file/tests/unit/c/test-file-stream_write.c | 16 ++++----- .../f_file/tests/unit/c/test-file-stream_write.h | 4 +-- .../tests/unit/c/test-file-stream_write_block.c | 16 ++++----- .../tests/unit/c/test-file-stream_write_block.h | 4 +-- .../tests/unit/c/test-file-stream_write_range.c | 18 +++++----- .../tests/unit/c/test-file-stream_write_range.h | 4 +-- .../tests/unit/c/test-file-stream_write_until.c | 16 ++++----- .../tests/unit/c/test-file-stream_write_until.h | 4 +-- level_0/f_file/tests/unit/c/test-file-type.c | 12 +++---- level_0/f_file/tests/unit/c/test-file-type.h | 4 +-- level_0/f_file/tests/unit/c/test-file-type_at.c | 12 +++---- level_0/f_file/tests/unit/c/test-file-type_at.h | 4 +-- level_0/f_file/tests/unit/c/test-file-umask_get.c | 12 +++---- level_0/f_file/tests/unit/c/test-file-umask_get.h | 4 +-- level_0/f_file/tests/unit/c/test-file-write.c | 16 ++++----- level_0/f_file/tests/unit/c/test-file-write.h | 4 +-- .../f_file/tests/unit/c/test-file-write_block.c | 16 ++++----- .../f_file/tests/unit/c/test-file-write_block.h | 4 +-- .../f_file/tests/unit/c/test-file-write_range.c | 18 +++++----- .../f_file/tests/unit/c/test-file-write_range.h | 4 +-- .../f_file/tests/unit/c/test-file-write_until.c | 16 ++++----- .../f_file/tests/unit/c/test-file-write_until.h | 4 +-- level_0/f_iki/tests/unit/c/test-iki-content_is.c | 12 +++---- level_0/f_iki/tests/unit/c/test-iki-content_is.h | 4 +-- .../tests/unit/c/test-iki-content_partial_is.c | 14 ++++---- .../tests/unit/c/test-iki-content_partial_is.h | 4 +-- level_0/f_iki/tests/unit/c/test-iki-read.c | 40 ++++++++++----------- level_0/f_iki/tests/unit/c/test-iki-read.h | 4 +-- level_0/f_limit/tests/unit/c/test-limit-process.c | 12 +++---- level_0/f_limit/tests/unit/c/test-limit-process.h | 4 +-- level_0/f_memory/tests/unit/c/test-memory-adjust.c | 20 +++++------ level_0/f_memory/tests/unit/c/test-memory-adjust.h | 4 +-- level_0/f_memory/tests/unit/c/test-memory-delete.c | 12 +++---- level_0/f_memory/tests/unit/c/test-memory-delete.h | 4 +-- .../f_memory/tests/unit/c/test-memory-destroy.c | 12 +++---- .../f_memory/tests/unit/c/test-memory-destroy.h | 4 +-- level_0/f_memory/tests/unit/c/test-memory-new.c | 12 +++---- level_0/f_memory/tests/unit/c/test-memory-new.h | 4 +-- .../tests/unit/c/test-memory-new_aligned.c | 12 +++---- .../tests/unit/c/test-memory-new_aligned.h | 4 +-- level_0/f_memory/tests/unit/c/test-memory-resize.c | 20 +++++------ level_0/f_memory/tests/unit/c/test-memory-resize.h | 4 +-- level_0/f_path/tests/unit/c/test-path-current.c | 12 +++---- level_0/f_path/tests/unit/c/test-path-current.h | 4 +-- .../tests/unit/c/test-path-directory_cleanup.c | 14 ++++---- .../tests/unit/c/test-path-directory_cleanup.h | 4 +-- level_0/f_path/tests/unit/c/test-path-real.c | 14 ++++---- level_0/f_path/tests/unit/c/test-path-real.h | 4 +-- 243 files changed, 958 insertions(+), 1455 deletions(-) diff --git a/level_0/f_account/tests/unit/c/test-account-by_id.c b/level_0/f_account/tests/unit/c/test-account-by_id.c index 384ef82..317ba11 100644 --- a/level_0/f_account/tests/unit/c/test-account-by_id.c +++ b/level_0/f_account/tests/unit/c/test-account-by_id.c @@ -66,16 +66,14 @@ void test__f_account_by_id__not_found(void **state) { macro_f_account_t_delete_simple(account); } -#ifndef _di_level_0_parameter_checking_ - void test__f_account_by_id__parameter_checking(void **state) { +void test__f_account_by_id__parameter_checking(void **state) { - { - const f_status_t status = f_account_by_id(0, 0); + { + const f_status_t status = f_account_by_id(0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_account_by_id__works(void **state) { diff --git a/level_0/f_account/tests/unit/c/test-account-by_id.h b/level_0/f_account/tests/unit/c/test-account-by_id.h index 7910a76..1ba72ed 100644 --- a/level_0/f_account/tests/unit/c/test-account-by_id.h +++ b/level_0/f_account/tests/unit/c/test-account-by_id.h @@ -29,9 +29,7 @@ extern void test__f_account_by_id__not_found(void **state); * * @see f_account_by_id() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_account_by_id__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_account_by_id__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_account/tests/unit/c/test-account-by_name.c b/level_0/f_account/tests/unit/c/test-account-by_name.c index fb59b4d..b302eb8 100644 --- a/level_0/f_account/tests/unit/c/test-account-by_name.c +++ b/level_0/f_account/tests/unit/c/test-account-by_name.c @@ -74,18 +74,16 @@ void test__f_account_by_name__not_found(void **state) { macro_f_account_t_delete_simple(account); } -#ifndef _di_level_0_parameter_checking_ - void test__f_account_by_name__parameter_checking(void **state) { +void test__f_account_by_name__parameter_checking(void **state) { - const f_string_static_t name = f_string_static_t_initialize; + const f_string_static_t name = f_string_static_t_initialize; - { - const f_status_t status = f_account_by_name(name, 0); + { + const f_status_t status = f_account_by_name(name, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_account_by_name__works(void **state) { diff --git a/level_0/f_account/tests/unit/c/test-account-by_name.h b/level_0/f_account/tests/unit/c/test-account-by_name.h index 22129af..70c3d31 100644 --- a/level_0/f_account/tests/unit/c/test-account-by_name.h +++ b/level_0/f_account/tests/unit/c/test-account-by_name.h @@ -29,9 +29,7 @@ extern void test__f_account_by_name__not_found(void **state); * * @see f_account_by_name() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_account_by_name__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_account_by_name__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_account/tests/unit/c/test-account-group_id_by_name.c b/level_0/f_account/tests/unit/c/test-account-group_id_by_name.c index abe7e5f..1700f45 100644 --- a/level_0/f_account/tests/unit/c/test-account-group_id_by_name.c +++ b/level_0/f_account/tests/unit/c/test-account-group_id_by_name.c @@ -70,18 +70,16 @@ void test__f_account_group_id_by_name__not_found(void **state) { } } -#ifndef _di_level_0_parameter_checking_ - void test__f_account_group_id_by_name__parameter_checking(void **state) { +void test__f_account_group_id_by_name__parameter_checking(void **state) { - const f_string_static_t name = f_string_static_t_initialize; + const f_string_static_t name = f_string_static_t_initialize; - { - const f_status_t status = f_account_group_id_by_name(name, 0); + { + const f_status_t status = f_account_group_id_by_name(name, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_account_group_id_by_name__works(void **state) { diff --git a/level_0/f_account/tests/unit/c/test-account-group_id_by_name.h b/level_0/f_account/tests/unit/c/test-account-group_id_by_name.h index 7f3ea75..7f147c8 100644 --- a/level_0/f_account/tests/unit/c/test-account-group_id_by_name.h +++ b/level_0/f_account/tests/unit/c/test-account-group_id_by_name.h @@ -29,9 +29,7 @@ extern void test__f_account_group_id_by_name__not_found(void **state); * * @see f_account_group_id_by_name() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_account_group_id_by_name__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_account_group_id_by_name__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_account/tests/unit/c/test-account-group_name_by_id.c b/level_0/f_account/tests/unit/c/test-account-group_name_by_id.c index 72b31ba..3009313 100644 --- a/level_0/f_account/tests/unit/c/test-account-group_name_by_id.c +++ b/level_0/f_account/tests/unit/c/test-account-group_name_by_id.c @@ -66,16 +66,14 @@ void test__f_account_group_name_by_id__not_found(void **state) { f_string_dynamic_resize(0, &name); } -#ifndef _di_level_0_parameter_checking_ - void test__f_account_group_name_by_id__parameter_checking(void **state) { +void test__f_account_group_name_by_id__parameter_checking(void **state) { - { - const f_status_t status = f_account_group_name_by_id(0, 0); + { + const f_status_t status = f_account_group_name_by_id(0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_account_group_name_by_id__works(void **state) { diff --git a/level_0/f_account/tests/unit/c/test-account-group_name_by_id.h b/level_0/f_account/tests/unit/c/test-account-group_name_by_id.h index 785c39b..7bb7f27 100644 --- a/level_0/f_account/tests/unit/c/test-account-group_name_by_id.h +++ b/level_0/f_account/tests/unit/c/test-account-group_name_by_id.h @@ -29,9 +29,7 @@ extern void test__f_account_group_name_by_id__not_found(void **state); * * @see f_account_group_name_by_id() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_account_group_name_by_id__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_account_group_name_by_id__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_account/tests/unit/c/test-account-id_by_name.c b/level_0/f_account/tests/unit/c/test-account-id_by_name.c index ebac5ea..2d71032 100644 --- a/level_0/f_account/tests/unit/c/test-account-id_by_name.c +++ b/level_0/f_account/tests/unit/c/test-account-id_by_name.c @@ -70,18 +70,16 @@ void test__f_account_id_by_name__not_found(void **state) { } } -#ifndef _di_level_0_parameter_checking_ - void test__f_account_id_by_name__parameter_checking(void **state) { +void test__f_account_id_by_name__parameter_checking(void **state) { - const f_string_static_t name = f_string_static_t_initialize; + const f_string_static_t name = f_string_static_t_initialize; - { - const f_status_t status = f_account_id_by_name(name, 0); + { + const f_status_t status = f_account_id_by_name(name, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_account_id_by_name__works(void **state) { diff --git a/level_0/f_account/tests/unit/c/test-account-id_by_name.h b/level_0/f_account/tests/unit/c/test-account-id_by_name.h index 1aa6199..f5a7cfa 100644 --- a/level_0/f_account/tests/unit/c/test-account-id_by_name.h +++ b/level_0/f_account/tests/unit/c/test-account-id_by_name.h @@ -29,9 +29,7 @@ extern void test__f_account_id_by_name__not_found(void **state); * * @see f_account_id_by_name() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_account_id_by_name__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_account_id_by_name__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_account/tests/unit/c/test-account-name_by_id.c b/level_0/f_account/tests/unit/c/test-account-name_by_id.c index 1658917..e8bf6d9 100644 --- a/level_0/f_account/tests/unit/c/test-account-name_by_id.c +++ b/level_0/f_account/tests/unit/c/test-account-name_by_id.c @@ -66,16 +66,14 @@ void test__f_account_name_by_id__not_found(void **state) { f_string_dynamic_resize(0, &name); } -#ifndef _di_level_0_parameter_checking_ - void test__f_account_name_by_id__parameter_checking(void **state) { +void test__f_account_name_by_id__parameter_checking(void **state) { - { - const f_status_t status = f_account_name_by_id(0, 0); + { + const f_status_t status = f_account_name_by_id(0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_account_name_by_id__works(void **state) { diff --git a/level_0/f_account/tests/unit/c/test-account-name_by_id.h b/level_0/f_account/tests/unit/c/test-account-name_by_id.h index 6920bb4..f69a8cb 100644 --- a/level_0/f_account/tests/unit/c/test-account-name_by_id.h +++ b/level_0/f_account/tests/unit/c/test-account-name_by_id.h @@ -29,9 +29,7 @@ extern void test__f_account_name_by_id__not_found(void **state); * * @see f_account_name_by_id() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_account_name_by_id__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_account_name_by_id__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-ambient_get.c b/level_0/f_capability/tests/unit/c/test-capability-ambient_get.c index 1642165..317292b 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-ambient_get.c +++ b/level_0/f_capability/tests/unit/c/test-capability-ambient_get.c @@ -22,18 +22,16 @@ void test__f_capability_ambient_get__fails(void **state) { #endif // !defined(_di_libcap_) && !defined(_libcap_legacy_only_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_ambient_get__parameter_checking(void **state) { +void test__f_capability_ambient_get__parameter_checking(void **state) { - const f_capability_value_t value = f_capability_value_t_initialize; + const f_capability_value_t value = f_capability_value_t_initialize; - { - const f_status_t status = f_capability_ambient_get(value, 0); + { + const f_status_t status = f_capability_ambient_get(value, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_ambient_get__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-ambient_get.h b/level_0/f_capability/tests/unit/c/test-capability-ambient_get.h index 4e8a39b..5fc5cc3 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-ambient_get.h +++ b/level_0/f_capability/tests/unit/c/test-capability-ambient_get.h @@ -22,9 +22,7 @@ extern void test__f_capability_ambient_get__fails(void **state); * * @see f_capability_ambient_get() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_ambient_get__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_ambient_get__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-clear.c b/level_0/f_capability/tests/unit/c/test-capability-clear.c index 7a42e82..da2255b 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-clear.c +++ b/level_0/f_capability/tests/unit/c/test-capability-clear.c @@ -36,16 +36,14 @@ void test__f_capability_clear__fails(void **state) { #endif // !defined(_di_libcap_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_clear__parameter_checking(void **state) { +void test__f_capability_clear__parameter_checking(void **state) { - { - const f_status_t status = f_capability_clear(0); + { + const f_status_t status = f_capability_clear(0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_clear__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-clear.h b/level_0/f_capability/tests/unit/c/test-capability-clear.h index 392ac7e..70a99aa 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-clear.h +++ b/level_0/f_capability/tests/unit/c/test-capability-clear.h @@ -22,9 +22,7 @@ extern void test__f_capability_clear__fails(void **state); * * @see f_capability_clear() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_clear__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_clear__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-clear_flag.c b/level_0/f_capability/tests/unit/c/test-capability-clear_flag.c index 8eba172..e361f37 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-clear_flag.c +++ b/level_0/f_capability/tests/unit/c/test-capability-clear_flag.c @@ -8,7 +8,7 @@ extern "C" { #ifndef _di_level_0_parameter_checking_ void test__f_capability_clear_flag__parameter_checking(void **state) { - const f_capability_flag_t flag = f_capability_flag_t_initialize; + const f_capability_flag_t flag = f_capability_flag_t_initialize; { const f_status_t status = f_capability_clear_flag(flag, 0); diff --git a/level_0/f_capability/tests/unit/c/test-capability-clear_flag.h b/level_0/f_capability/tests/unit/c/test-capability-clear_flag.h index 388e3e3..e566356 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-clear_flag.h +++ b/level_0/f_capability/tests/unit/c/test-capability-clear_flag.h @@ -22,9 +22,7 @@ extern void test__f_capability_clear_flag__fails(void **state); * * @see f_capability_clear_flag() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_clear_flag__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_clear_flag__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-copy.c b/level_0/f_capability/tests/unit/c/test-capability-copy.c index 74d3433..9481a62 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-copy.c +++ b/level_0/f_capability/tests/unit/c/test-capability-copy.c @@ -23,18 +23,16 @@ void test__f_capability_copy__fails(void **state) { #endif // !defined(_di_libcap_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_copy__parameter_checking(void **state) { +void test__f_capability_copy__parameter_checking(void **state) { - const f_capability_t capability = f_capability_t_initialize; + const f_capability_t capability = f_capability_t_initialize; - { - const f_status_t status = f_capability_copy(capability, 0); + { + const f_status_t status = f_capability_copy(capability, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_copy__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-copy.h b/level_0/f_capability/tests/unit/c/test-capability-copy.h index 6815e00..937ecc4 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-copy.h +++ b/level_0/f_capability/tests/unit/c/test-capability-copy.h @@ -29,8 +29,6 @@ extern void test__f_capability_copy__works(void **state); * * @see f_capability_copy() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_copy__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_copy__parameter_checking(void **state); #endif // _TEST__F_capability__copy_h diff --git a/level_0/f_capability/tests/unit/c/test-capability-copy_external.c b/level_0/f_capability/tests/unit/c/test-capability-copy_external.c index 4241bd1..0052c31 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-copy_external.c +++ b/level_0/f_capability/tests/unit/c/test-capability-copy_external.c @@ -38,18 +38,16 @@ void test__f_capability_copy_external__fails(void **state) { #endif // !defined(_di_libcap_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_copy_external__parameter_checking(void **state) { +void test__f_capability_copy_external__parameter_checking(void **state) { - f_capability_t capability = f_capability_t_initialize; + f_capability_t capability = f_capability_t_initialize; - { - const f_status_t status = f_capability_copy_external(capability, 0, 0, 0); + { + const f_status_t status = f_capability_copy_external(capability, 0, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_copy_external__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-copy_external.h b/level_0/f_capability/tests/unit/c/test-capability-copy_external.h index 3d0c9a8..819c445 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-copy_external.h +++ b/level_0/f_capability/tests/unit/c/test-capability-copy_external.h @@ -22,9 +22,7 @@ extern void test__f_capability_copy_external__fails(void **state); * * @see f_capability_copy_external() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_copy_external__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_copy_external__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-copy_internal.c b/level_0/f_capability/tests/unit/c/test-capability-copy_internal.c index bc07f4f..f8d93c2 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-copy_internal.c +++ b/level_0/f_capability/tests/unit/c/test-capability-copy_internal.c @@ -36,26 +36,24 @@ void test__f_capability_copy_internal__fails(void **state) { #endif // !defined(_di_libcap_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_copy_internal__parameter_checking(void **state) { +void test__f_capability_copy_internal__parameter_checking(void **state) { - f_capability_t capability = f_capability_t_initialize; - int stub = 0; - void *external = (void *) &stub; + f_capability_t capability = f_capability_t_initialize; + int stub = 0; + void *external = (void *) &stub; - { - const f_status_t status = f_capability_copy_internal(0, &capability); + { + const f_status_t status = f_capability_copy_internal(0, &capability); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); + } - { - const f_status_t status = f_capability_copy_internal(external, 0); + { + const f_status_t status = f_capability_copy_internal(external, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_copy_internal__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-copy_internal.h b/level_0/f_capability/tests/unit/c/test-capability-copy_internal.h index 3e64b41..6cfe511 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-copy_internal.h +++ b/level_0/f_capability/tests/unit/c/test-capability-copy_internal.h @@ -22,9 +22,7 @@ extern void test__f_capability_copy_internal__fails(void **state); * * @see f_capability_copy_internal() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_copy_internal__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_copy_internal__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-delete.c b/level_0/f_capability/tests/unit/c/test-capability-delete.c index 5be93ec..cf453a0 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-delete.c +++ b/level_0/f_capability/tests/unit/c/test-capability-delete.c @@ -34,16 +34,14 @@ void test__f_capability_delete__fails(void **state) { #endif // !defined(_di_libcap_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_delete__parameter_checking(void **state) { +void test__f_capability_delete__parameter_checking(void **state) { - { - const f_status_t status = f_capability_delete(0); + { + const f_status_t status = f_capability_delete(0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_delete__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-delete.h b/level_0/f_capability/tests/unit/c/test-capability-delete.h index c834362..85c4dac 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-delete.h +++ b/level_0/f_capability/tests/unit/c/test-capability-delete.h @@ -22,9 +22,7 @@ extern void test__f_capability_delete__fails(void **state); * * @see f_capability_delete() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_delete__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_delete__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-file_descriptor_get.c b/level_0/f_capability/tests/unit/c/test-capability-file_descriptor_get.c index 11c3e96..c531bf9 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-file_descriptor_get.c +++ b/level_0/f_capability/tests/unit/c/test-capability-file_descriptor_get.c @@ -47,18 +47,16 @@ void test__f_capability_file_descriptor_get__fails(void **state) { #endif // !defined(_di_libcap_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_file_descriptor_get__parameter_checking(void **state) { +void test__f_capability_file_descriptor_get__parameter_checking(void **state) { - const int descriptor = 0; + const int descriptor = 0; - { - const f_status_t status = f_capability_file_descriptor_get(descriptor, 0); + { + const f_status_t status = f_capability_file_descriptor_get(descriptor, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_file_descriptor_get__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-file_descriptor_get.h b/level_0/f_capability/tests/unit/c/test-capability-file_descriptor_get.h index e7df00f..ca8eb6e 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-file_descriptor_get.h +++ b/level_0/f_capability/tests/unit/c/test-capability-file_descriptor_get.h @@ -22,9 +22,7 @@ extern void test__f_capability_file_descriptor_get__fails(void **state); * * @see f_capability_file_descriptor_get() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_file_descriptor_get__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_file_descriptor_get__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-file_get.c b/level_0/f_capability/tests/unit/c/test-capability-file_get.c index 0af59dc..79ad9aa 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-file_get.c +++ b/level_0/f_capability/tests/unit/c/test-capability-file_get.c @@ -47,18 +47,16 @@ void test__f_capability_file_get__fails(void **state) { #endif // !defined(_di_libcap_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_file_get__parameter_checking(void **state) { +void test__f_capability_file_get__parameter_checking(void **state) { const f_string_static_t path = f_string_static_t_initialize; - { - const f_status_t status = f_capability_file_get(path, 0); + { + const f_status_t status = f_capability_file_get(path, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_file_get__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-file_get.h b/level_0/f_capability/tests/unit/c/test-capability-file_get.h index c61bfec..44b24ec 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-file_get.h +++ b/level_0/f_capability/tests/unit/c/test-capability-file_get.h @@ -22,9 +22,7 @@ extern void test__f_capability_file_get__fails(void **state); * * @see f_capability_file_get() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_file_get__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_file_get__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-flag_get.c b/level_0/f_capability/tests/unit/c/test-capability-flag_get.c index 9815643..97d3e01 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-flag_get.c +++ b/level_0/f_capability/tests/unit/c/test-capability-flag_get.c @@ -35,20 +35,18 @@ void test__f_capability_flag_get__fails(void **state) { #endif // !defined(_di_libcap_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_flag_get__parameter_checking(void **state) { +void test__f_capability_flag_get__parameter_checking(void **state) { - const f_capability_flag_t flag = f_capability_flag_t_initialize; - const f_capability_t capability = f_capability_t_initialize; - const f_capability_value_t capability_value = f_capability_value_t_initialize; + const f_capability_flag_t flag = f_capability_flag_t_initialize; + const f_capability_t capability = f_capability_t_initialize; + const f_capability_value_t capability_value = f_capability_value_t_initialize; - { - const f_status_t status = f_capability_flag_get(capability, capability_value, flag, 0); + { + const f_status_t status = f_capability_flag_get(capability, capability_value, flag, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_flag_get__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-flag_get.h b/level_0/f_capability/tests/unit/c/test-capability-flag_get.h index f1f8d6e..a0faf8f 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-flag_get.h +++ b/level_0/f_capability/tests/unit/c/test-capability-flag_get.h @@ -22,9 +22,7 @@ extern void test__f_capability_flag_get__fails(void **state); * * @see f_capability_flag_get() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_flag_get__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_flag_get__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-flag_set.c b/level_0/f_capability/tests/unit/c/test-capability-flag_set.c index fc5c50c..d00e6cb 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-flag_set.c +++ b/level_0/f_capability/tests/unit/c/test-capability-flag_set.c @@ -35,20 +35,18 @@ void test__f_capability_flag_set__fails(void **state) { #endif // !defined(_di_libcap_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_flag_set__parameter_checking(void **state) { +void test__f_capability_flag_set__parameter_checking(void **state) { - const f_capability_flag_t flag = f_capability_flag_t_initialize; - const f_capability_flag_value_t value = f_capability_flag_value_t_initialize; - const f_int32s_t codes = f_int32s_t_initialize; + const f_capability_flag_t flag = f_capability_flag_t_initialize; + const f_capability_flag_value_t value = f_capability_flag_value_t_initialize; + const f_int32s_t codes = f_int32s_t_initialize; - { - const f_status_t status = f_capability_flag_set(flag, value, codes, 0); + { + const f_status_t status = f_capability_flag_set(flag, value, codes, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_flag_set__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-flag_set.h b/level_0/f_capability/tests/unit/c/test-capability-flag_set.h index ce3ab95..877acc0 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-flag_set.h +++ b/level_0/f_capability/tests/unit/c/test-capability-flag_set.h @@ -22,9 +22,7 @@ extern void test__f_capability_flag_set__fails(void **state); * * @see f_capability_flag_set() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_flag_set__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_flag_set__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-from_name.c b/level_0/f_capability/tests/unit/c/test-capability-from_name.c index 2cf9a6d..c332a91 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-from_name.c +++ b/level_0/f_capability/tests/unit/c/test-capability-from_name.c @@ -35,18 +35,16 @@ void test__f_capability_from_name__fails(void **state) { #endif // !defined(_di_libcap_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_from_name__parameter_checking(void **state) { +void test__f_capability_from_name__parameter_checking(void **state) { - const f_string_static_t name = f_string_static_t_initialize; + const f_string_static_t name = f_string_static_t_initialize; - { - const f_status_t status = f_capability_from_name(name, 0); + { + const f_status_t status = f_capability_from_name(name, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_from_name__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-from_name.h b/level_0/f_capability/tests/unit/c/test-capability-from_name.h index 0a6ba81..8b6efb1 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-from_name.h +++ b/level_0/f_capability/tests/unit/c/test-capability-from_name.h @@ -22,9 +22,7 @@ extern void test__f_capability_from_name__fails(void **state); * * @see f_capability_from_name() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_from_name__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_from_name__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-from_text.c b/level_0/f_capability/tests/unit/c/test-capability-from_text.c index 7e92a9d..65f2a3b 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-from_text.c +++ b/level_0/f_capability/tests/unit/c/test-capability-from_text.c @@ -35,18 +35,16 @@ void test__f_capability_from_text__fails(void **state) { #endif // !defined(_di_libcap_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_from_text__parameter_checking(void **state) { +void test__f_capability_from_text__parameter_checking(void **state) { - const f_string_static_t text = f_string_static_t_initialize; + const f_string_static_t text = f_string_static_t_initialize; - { - const f_status_t status = f_capability_from_text(text, 0); + { + const f_status_t status = f_capability_from_text(text, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_from_text__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-from_text.h b/level_0/f_capability/tests/unit/c/test-capability-from_text.h index 0179fc5..65e0788 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-from_text.h +++ b/level_0/f_capability/tests/unit/c/test-capability-from_text.h @@ -22,9 +22,7 @@ extern void test__f_capability_from_text__fails(void **state); * * @see f_capability_from_text() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_from_text__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_from_text__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-initialize.c b/level_0/f_capability/tests/unit/c/test-capability-initialize.c index 004227b..79300da 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-initialize.c +++ b/level_0/f_capability/tests/unit/c/test-capability-initialize.c @@ -34,16 +34,14 @@ void test__f_capability_initialize__fails(void **state) { #endif // !defined(_di_libcap_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_initialize__parameter_checking(void **state) { +void test__f_capability_initialize__parameter_checking(void **state) { - { - const f_status_t status = f_capability_initialize(0); + { + const f_status_t status = f_capability_initialize(0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_initialize__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-initialize.h b/level_0/f_capability/tests/unit/c/test-capability-initialize.h index bfacec0..0c626ec 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-initialize.h +++ b/level_0/f_capability/tests/unit/c/test-capability-initialize.h @@ -22,9 +22,7 @@ extern void test__f_capability_initialize__fails(void **state); * * @see f_capability_initialize() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_initialize__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_initialize__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-mode_get.c b/level_0/f_capability/tests/unit/c/test-capability-mode_get.c index 9f704ee..58d9933 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-mode_get.c +++ b/level_0/f_capability/tests/unit/c/test-capability-mode_get.c @@ -5,16 +5,14 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_mode_get__parameter_checking(void **state) { +void test__f_capability_mode_get__parameter_checking(void **state) { - { - const f_status_t status = f_capability_mode_get(0); + { + const f_status_t status = f_capability_mode_get(0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_mode_get__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-mode_get.h b/level_0/f_capability/tests/unit/c/test-capability-mode_get.h index 269b999..5214ba3 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-mode_get.h +++ b/level_0/f_capability/tests/unit/c/test-capability-mode_get.h @@ -17,9 +17,7 @@ * * @see f_capability_mode_get() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_mode_get__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_mode_get__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-mode_get_name.c b/level_0/f_capability/tests/unit/c/test-capability-mode_get_name.c index 88c216a..79c576a 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-mode_get_name.c +++ b/level_0/f_capability/tests/unit/c/test-capability-mode_get_name.c @@ -5,18 +5,16 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_mode_get_name__parameter_checking(void **state) { +void test__f_capability_mode_get_name__parameter_checking(void **state) { - const f_capability_mode_t mode = f_capability_mode_t_initialize; + const f_capability_mode_t mode = f_capability_mode_t_initialize; - { - const f_status_t status = f_capability_mode_get_name(mode, 0); + { + const f_status_t status = f_capability_mode_get_name(mode, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_mode_get_name__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-mode_get_name.h b/level_0/f_capability/tests/unit/c/test-capability-mode_get_name.h index abc3b70..a1ab83f 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-mode_get_name.h +++ b/level_0/f_capability/tests/unit/c/test-capability-mode_get_name.h @@ -17,9 +17,7 @@ * * @see f_capability_mode_get_name() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_mode_get_name__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_mode_get_name__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-owner_get.c b/level_0/f_capability/tests/unit/c/test-capability-owner_get.c index f03f545..949fadc 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-owner_get.c +++ b/level_0/f_capability/tests/unit/c/test-capability-owner_get.c @@ -5,18 +5,16 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_owner_get__parameter_checking(void **state) { +void test__f_capability_owner_get__parameter_checking(void **state) { - const f_capability_t capability = f_capability_t_initialize; + const f_capability_t capability = f_capability_t_initialize; - { - const f_status_t status = f_capability_owner_get(capability, 0); + { + const f_status_t status = f_capability_owner_get(capability, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_owner_get__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-owner_get.h b/level_0/f_capability/tests/unit/c/test-capability-owner_get.h index ad5d8f6..20d75c5 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-owner_get.h +++ b/level_0/f_capability/tests/unit/c/test-capability-owner_get.h @@ -17,9 +17,7 @@ * * @see f_capability_owner_get() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_owner_get__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_owner_get__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-process_bound_drop.c b/level_0/f_capability/tests/unit/c/test-capability-process_bound_drop.c index f487425..e2041fe 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-process_bound_drop.c +++ b/level_0/f_capability/tests/unit/c/test-capability-process_bound_drop.c @@ -37,18 +37,16 @@ void test__f_capability_process_bound_drop__fails(void **state) { #endif // !defined(_di_libcap_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_process_bound_drop__parameter_checking(void **state) { +void test__f_capability_process_bound_drop__parameter_checking(void **state) { - const f_capability_value_t value = f_capability_value_t_initialize; + const f_capability_value_t value = f_capability_value_t_initialize; - { - const f_status_t status = f_capability_process_bound_drop(value, 0); + { + const f_status_t status = f_capability_process_bound_drop(value, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_process_bound_drop__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-process_bound_drop.h b/level_0/f_capability/tests/unit/c/test-capability-process_bound_drop.h index b84b135..b62e347 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-process_bound_drop.h +++ b/level_0/f_capability/tests/unit/c/test-capability-process_bound_drop.h @@ -22,9 +22,7 @@ extern void test__f_capability_process_bound_drop__fails(void **state); * * @see f_capability_process_bound_drop() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_process_bound_drop__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_process_bound_drop__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-process_bound_get.c b/level_0/f_capability/tests/unit/c/test-capability-process_bound_get.c index 7810c8c..8fd02d7 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-process_bound_get.c +++ b/level_0/f_capability/tests/unit/c/test-capability-process_bound_get.c @@ -31,18 +31,16 @@ void test__f_capability_process_bound_get__fails(void **state) { #endif // !defined(_di_libcap_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_process_bound_get__parameter_checking(void **state) { +void test__f_capability_process_bound_get__parameter_checking(void **state) { - const f_capability_value_t value = f_capability_value_t_initialize; + const f_capability_value_t value = f_capability_value_t_initialize; - { - const f_status_t status = f_capability_process_bound_get(value, 0); + { + const f_status_t status = f_capability_process_bound_get(value, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_process_bound_get__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-process_bound_get.h b/level_0/f_capability/tests/unit/c/test-capability-process_bound_get.h index c66aac6..999b354 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-process_bound_get.h +++ b/level_0/f_capability/tests/unit/c/test-capability-process_bound_get.h @@ -22,9 +22,7 @@ extern void test__f_capability_process_bound_get__fails(void **state); * * @see f_capability_process_bound_get() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_process_bound_get__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_process_bound_get__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-process_get.c b/level_0/f_capability/tests/unit/c/test-capability-process_get.c index baf37bf..81215f4 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-process_get.c +++ b/level_0/f_capability/tests/unit/c/test-capability-process_get.c @@ -34,16 +34,14 @@ void test__f_capability_process_get__fails(void **state) { #endif // !defined(_di_libcap_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_process_get__parameter_checking(void **state) { +void test__f_capability_process_get__parameter_checking(void **state) { - { - const f_status_t status = f_capability_process_get(0); + { + const f_status_t status = f_capability_process_get(0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_process_get__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-process_get.h b/level_0/f_capability/tests/unit/c/test-capability-process_get.h index 314c2e0..8c31133 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-process_get.h +++ b/level_0/f_capability/tests/unit/c/test-capability-process_get.h @@ -22,9 +22,7 @@ extern void test__f_capability_process_get__fails(void **state); * * @see f_capability_process_get() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_process_get__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_process_get__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-process_get_by_id.c b/level_0/f_capability/tests/unit/c/test-capability-process_get_by_id.c index bb22ad0..a85481b 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-process_get_by_id.c +++ b/level_0/f_capability/tests/unit/c/test-capability-process_get_by_id.c @@ -31,16 +31,14 @@ void test__f_capability_process_get_by_id__fails(void **state) { #endif // !defined(_di_libcap_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_process_get_by_id__parameter_checking(void **state) { +void test__f_capability_process_get_by_id__parameter_checking(void **state) { - { - const f_status_t status = f_capability_process_get_by_id(0, 0); + { + const f_status_t status = f_capability_process_get_by_id(0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_process_get_by_id__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-process_get_by_id.h b/level_0/f_capability/tests/unit/c/test-capability-process_get_by_id.h index 68e0bad..cdd1b52 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-process_get_by_id.h +++ b/level_0/f_capability/tests/unit/c/test-capability-process_get_by_id.h @@ -22,9 +22,7 @@ extern void test__f_capability_process_get_by_id__fails(void **state); * * @see f_capability_process_get_by_id() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_process_get_by_id__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_process_get_by_id__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-security_bits_get.c b/level_0/f_capability/tests/unit/c/test-capability-security_bits_get.c index ceed172..fc63302 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-security_bits_get.c +++ b/level_0/f_capability/tests/unit/c/test-capability-security_bits_get.c @@ -36,16 +36,14 @@ void test__f_capability_security_bits_get__fails(void **state) { #endif // !defined(_di_libcap_) && !defined(_libcap_legacy_only_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_security_bits_get__parameter_checking(void **state) { +void test__f_capability_security_bits_get__parameter_checking(void **state) { - { - const f_status_t status = f_capability_security_bits_get(0); + { + const f_status_t status = f_capability_security_bits_get(0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_security_bits_get__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-security_bits_get.h b/level_0/f_capability/tests/unit/c/test-capability-security_bits_get.h index 1d86a89..db60314 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-security_bits_get.h +++ b/level_0/f_capability/tests/unit/c/test-capability-security_bits_get.h @@ -22,9 +22,7 @@ extern void test__f_capability_security_bits_get__fails(void **state); * * @see f_capability_security_bits_get() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_security_bits_get__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_security_bits_get__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-size.c b/level_0/f_capability/tests/unit/c/test-capability-size.c index c7c2d6c..b29ffb5 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-size.c +++ b/level_0/f_capability/tests/unit/c/test-capability-size.c @@ -37,18 +37,16 @@ void test__f_capability_size__fails(void **state) { #endif // !defined(_di_libcap_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_size__parameter_checking(void **state) { +void test__f_capability_size__parameter_checking(void **state) { - const f_capability_t capability = f_capability_t_initialize; + const f_capability_t capability = f_capability_t_initialize; - { - const f_status_t status = f_capability_size(capability, 0); + { + const f_status_t status = f_capability_size(capability, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_size__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-size.h b/level_0/f_capability/tests/unit/c/test-capability-size.h index 1896df7..35baec5 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-size.h +++ b/level_0/f_capability/tests/unit/c/test-capability-size.h @@ -22,9 +22,7 @@ extern void test__f_capability_size__fails(void **state); * * @see f_capability_size() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_size__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_size__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-to_name.c b/level_0/f_capability/tests/unit/c/test-capability-to_name.c index 581a300..4815fca 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-to_name.c +++ b/level_0/f_capability/tests/unit/c/test-capability-to_name.c @@ -36,18 +36,16 @@ void test__f_capability_to_name__fails(void **state) { #endif // !defined(_di_libcap_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_to_name__parameter_checking(void **state) { +void test__f_capability_to_name__parameter_checking(void **state) { - const int code = CAP_CHOWN; + const int code = CAP_CHOWN; - { - const f_status_t status = f_capability_to_name(code, 0); + { + const f_status_t status = f_capability_to_name(code, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_to_name__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-to_name.h b/level_0/f_capability/tests/unit/c/test-capability-to_name.h index 639ba3b..79fb97c 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-to_name.h +++ b/level_0/f_capability/tests/unit/c/test-capability-to_name.h @@ -22,9 +22,7 @@ extern void test__f_capability_to_name__fails(void **state); * * @see f_capability_to_name() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_to_name__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_to_name__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability-to_text.c b/level_0/f_capability/tests/unit/c/test-capability-to_text.c index 0d0416e..2d8d3bd 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-to_text.c +++ b/level_0/f_capability/tests/unit/c/test-capability-to_text.c @@ -36,18 +36,16 @@ void test__f_capability_to_text__fails(void **state) { #endif // !defined(_di_libcap_) } -#ifndef _di_level_0_parameter_checking_ - void test__f_capability_to_text__parameter_checking(void **state) { +void test__f_capability_to_text__parameter_checking(void **state) { - const f_capability_t capability = f_capability_t_initialize; + const f_capability_t capability = f_capability_t_initialize; - { - const f_status_t status = f_capability_to_text(capability, 0); + { + const f_status_t status = f_capability_to_text(capability, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_capability_to_text__works(void **state) { diff --git a/level_0/f_capability/tests/unit/c/test-capability-to_text.h b/level_0/f_capability/tests/unit/c/test-capability-to_text.h index 2adc8ef..5a86988 100644 --- a/level_0/f_capability/tests/unit/c/test-capability-to_text.h +++ b/level_0/f_capability/tests/unit/c/test-capability-to_text.h @@ -22,9 +22,7 @@ extern void test__f_capability_to_text__fails(void **state); * * @see f_capability_to_text() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_capability_to_text__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_capability_to_text__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_capability/tests/unit/c/test-capability.c b/level_0/f_capability/tests/unit/c/test-capability.c index 4a2dbe6..f9de116 100644 --- a/level_0/f_capability/tests/unit/c/test-capability.c +++ b/level_0/f_capability/tests/unit/c/test-capability.c @@ -79,16 +79,13 @@ int main(void) { cmocka_unit_test(test__f_capability_initialize__fails), cmocka_unit_test(test__f_capability_initialize__works), - // cap_get_mode() doesn't return failure. cmocka_unit_test(test__f_capability_mode_get__works), - // cap_mode_name() doesn't return failure. cmocka_unit_test(test__f_capability_mode_get_name__works), cmocka_unit_test(test__f_capability_mode_set__fails), cmocka_unit_test(test__f_capability_mode_set__works), - // cap_get_nsowner() doesn't return failure. cmocka_unit_test(test__f_capability_owner_get__works), cmocka_unit_test(test__f_capability_owner_set__fails), @@ -118,13 +115,10 @@ int main(void) { cmocka_unit_test(test__f_capability_size__fails), cmocka_unit_test(test__f_capability_size__works), - // f_capability_supported() doesn't return failure. cmocka_unit_test(test__f_capability_supported__works), - // f_capability_supported_ambient() doesn't return failure. cmocka_unit_test(test__f_capability_supported_ambient__works), - // f_capability_supported_code() doesn't return failure. cmocka_unit_test(test__f_capability_supported_code__works), cmocka_unit_test(test__f_capability_to_name__fails), diff --git a/level_0/f_color/tests/unit/c/test-color-context_delete.c b/level_0/f_color/tests/unit/c/test-color-context_delete.c index fdc069b..bbbe942 100644 --- a/level_0/f_color/tests/unit/c/test-color-context_delete.c +++ b/level_0/f_color/tests/unit/c/test-color-context_delete.c @@ -108,16 +108,14 @@ void test__f_color_context_delete__frees_memory(void **state) { } } -#ifndef _di_level_0_parameter_checking_ - void test__f_color_context_delete__parameter_checking(void **state) { +void test__f_color_context_delete__parameter_checking(void **state) { - { - const f_status_t status = f_color_context_delete(0); + { + const f_status_t status = f_color_context_delete(0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} #ifdef __cplusplus } // extern "C" diff --git a/level_0/f_color/tests/unit/c/test-color-context_delete.h b/level_0/f_color/tests/unit/c/test-color-context_delete.h index 4355f72..af4537a 100644 --- a/level_0/f_color/tests/unit/c/test-color-context_delete.h +++ b/level_0/f_color/tests/unit/c/test-color-context_delete.h @@ -22,8 +22,6 @@ extern void test__f_color_context_delete__frees_memory(void **state); * * @see f_color_context_delete() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_color_context_delete__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_color_context_delete__parameter_checking(void **state); #endif // _TEST__F_color__delete diff --git a/level_0/f_color/tests/unit/c/test-color-context_destroy.c b/level_0/f_color/tests/unit/c/test-color-context_destroy.c index e5ff812..c85acd3 100644 --- a/level_0/f_color/tests/unit/c/test-color-context_destroy.c +++ b/level_0/f_color/tests/unit/c/test-color-context_destroy.c @@ -108,16 +108,14 @@ void test__f_color_context_destroy__frees_memory(void **state) { } } -#ifndef _di_level_0_parameter_checking_ - void test__f_color_context_destroy__parameter_checking(void **state) { +void test__f_color_context_destroy__parameter_checking(void **state) { - { - const f_status_t status = f_color_context_destroy(0); + { + const f_status_t status = f_color_context_destroy(0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} #ifdef __cplusplus } // extern "C" diff --git a/level_0/f_color/tests/unit/c/test-color-context_destroy.h b/level_0/f_color/tests/unit/c/test-color-context_destroy.h index a5cabbf..64bef84 100644 --- a/level_0/f_color/tests/unit/c/test-color-context_destroy.h +++ b/level_0/f_color/tests/unit/c/test-color-context_destroy.h @@ -22,8 +22,6 @@ extern void test__f_color_context_destroy__frees_memory(void **state); * * @see f_color_context_destroy() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_color_context_destroy__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_color_context_destroy__parameter_checking(void **state); #endif // _TEST__F_color__destroy diff --git a/level_0/f_color/tests/unit/c/test-color-load_context.c b/level_0/f_color/tests/unit/c/test-color-load_context.c index 79b9e65..3799bda 100644 --- a/level_0/f_color/tests/unit/c/test-color-load_context.c +++ b/level_0/f_color/tests/unit/c/test-color-load_context.c @@ -5,16 +5,14 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_color_load_context__parameter_checking(void **state) { +void test__f_color_load_context__parameter_checking(void **state) { - { - const f_status_t status = f_color_load_context(F_true, 0); + { + const f_status_t status = f_color_load_context(F_true, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_color_load_context__works(void **state) { diff --git a/level_0/f_color/tests/unit/c/test-color-load_context.h b/level_0/f_color/tests/unit/c/test-color-load_context.h index 3ecf4a6..0da2172 100644 --- a/level_0/f_color/tests/unit/c/test-color-load_context.h +++ b/level_0/f_color/tests/unit/c/test-color-load_context.h @@ -17,9 +17,7 @@ * * @see f_color_load_context() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_color_load_context__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_color_load_context__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_color/tests/unit/c/test-color-save_1.c b/level_0/f_color/tests/unit/c/test-color-save_1.c index e9db186..7db5cf7 100644 --- a/level_0/f_color/tests/unit/c/test-color-save_1.c +++ b/level_0/f_color/tests/unit/c/test-color-save_1.c @@ -5,19 +5,17 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_color_save_1_parameter_checking(void **state) { +void test__f_color_save_1_parameter_checking(void **state) { - const f_color_format_t format = f_color_format_t_initialize; - const f_string_static_t color = macro_f_string_static_t_initialize2("color", 5); + const f_color_format_t format = f_color_format_t_initialize; + const f_string_static_t color = macro_f_string_static_t_initialize2("color", 5); - { - const f_status_t status = f_color_save_1(format, color, 0); + { + const f_status_t status = f_color_save_1(format, color, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_color_save_1_works(void **state) { diff --git a/level_0/f_color/tests/unit/c/test-color-save_1.h b/level_0/f_color/tests/unit/c/test-color-save_1.h index d80b485..afc11fe 100644 --- a/level_0/f_color/tests/unit/c/test-color-save_1.h +++ b/level_0/f_color/tests/unit/c/test-color-save_1.h @@ -17,9 +17,7 @@ * * @see f_color_save_1() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_color_save_1_parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_color_save_1_parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_color/tests/unit/c/test-color-save_2.c b/level_0/f_color/tests/unit/c/test-color-save_2.c index ffb476f..3c3f806 100644 --- a/level_0/f_color/tests/unit/c/test-color-save_2.c +++ b/level_0/f_color/tests/unit/c/test-color-save_2.c @@ -5,19 +5,17 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_color_save_2_parameter_checking(void **state) { +void test__f_color_save_2_parameter_checking(void **state) { - const f_color_format_t format = f_color_format_t_initialize; - const f_string_static_t color = macro_f_string_static_t_initialize2("color", 5); + const f_color_format_t format = f_color_format_t_initialize; + const f_string_static_t color = macro_f_string_static_t_initialize2("color", 5); - { - const f_status_t status = f_color_save_2(format, color, color, 0); + { + const f_status_t status = f_color_save_2(format, color, color, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_color_save_2_works(void **state) { diff --git a/level_0/f_color/tests/unit/c/test-color-save_2.h b/level_0/f_color/tests/unit/c/test-color-save_2.h index 69c4422..0d47320 100644 --- a/level_0/f_color/tests/unit/c/test-color-save_2.h +++ b/level_0/f_color/tests/unit/c/test-color-save_2.h @@ -17,9 +17,7 @@ * * @see f_color_save_2() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_color_save_2_parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_color_save_2_parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_color/tests/unit/c/test-color-save_3.c b/level_0/f_color/tests/unit/c/test-color-save_3.c index fe6996d..d015b2c 100644 --- a/level_0/f_color/tests/unit/c/test-color-save_3.c +++ b/level_0/f_color/tests/unit/c/test-color-save_3.c @@ -5,19 +5,17 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_color_save_3_parameter_checking(void **state) { +void test__f_color_save_3_parameter_checking(void **state) { - const f_color_format_t format = f_color_format_t_initialize; - const f_string_static_t color = macro_f_string_static_t_initialize2("color", 5); + const f_color_format_t format = f_color_format_t_initialize; + const f_string_static_t color = macro_f_string_static_t_initialize2("color", 5); - { - const f_status_t status = f_color_save_3(format, color, color, color, 0); + { + const f_status_t status = f_color_save_3(format, color, color, color, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_color_save_3_works(void **state) { diff --git a/level_0/f_color/tests/unit/c/test-color-save_3.h b/level_0/f_color/tests/unit/c/test-color-save_3.h index 33b874e..493cc3a 100644 --- a/level_0/f_color/tests/unit/c/test-color-save_3.h +++ b/level_0/f_color/tests/unit/c/test-color-save_3.h @@ -17,9 +17,7 @@ * * @see f_color_save_3() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_color_save_3_parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_color_save_3_parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_color/tests/unit/c/test-color-save_4.c b/level_0/f_color/tests/unit/c/test-color-save_4.c index 98fd1bd..0117955 100644 --- a/level_0/f_color/tests/unit/c/test-color-save_4.c +++ b/level_0/f_color/tests/unit/c/test-color-save_4.c @@ -5,19 +5,17 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_color_save_4_parameter_checking(void **state) { +void test__f_color_save_4_parameter_checking(void **state) { - const f_color_format_t format = f_color_format_t_initialize; - const f_string_static_t color = macro_f_string_static_t_initialize2("color", 5); + const f_color_format_t format = f_color_format_t_initialize; + const f_string_static_t color = macro_f_string_static_t_initialize2("color", 5); - { - const f_status_t status = f_color_save_4(format, color, color, color, color, 0); + { + const f_status_t status = f_color_save_4(format, color, color, color, color, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_color_save_4_works(void **state) { diff --git a/level_0/f_color/tests/unit/c/test-color-save_4.h b/level_0/f_color/tests/unit/c/test-color-save_4.h index cf177ef..881df7e 100644 --- a/level_0/f_color/tests/unit/c/test-color-save_4.h +++ b/level_0/f_color/tests/unit/c/test-color-save_4.h @@ -17,9 +17,7 @@ * * @see f_color_save_4() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_color_save_4_parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_color_save_4_parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_color/tests/unit/c/test-color-save_5.c b/level_0/f_color/tests/unit/c/test-color-save_5.c index e3bf534..bd0b1a0 100644 --- a/level_0/f_color/tests/unit/c/test-color-save_5.c +++ b/level_0/f_color/tests/unit/c/test-color-save_5.c @@ -5,19 +5,17 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_color_save_5_parameter_checking(void **state) { +void test__f_color_save_5_parameter_checking(void **state) { - const f_color_format_t format = f_color_format_t_initialize; - const f_string_static_t color = macro_f_string_static_t_initialize2("color", 5); + const f_color_format_t format = f_color_format_t_initialize; + const f_string_static_t color = macro_f_string_static_t_initialize2("color", 5); - { - const f_status_t status = f_color_save_5(format, color, color, color, color, color, 0); + { + const f_status_t status = f_color_save_5(format, color, color, color, color, color, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_color_save_5_works(void **state) { diff --git a/level_0/f_color/tests/unit/c/test-color-save_5.h b/level_0/f_color/tests/unit/c/test-color-save_5.h index 6bc2aad..6e60dc8 100644 --- a/level_0/f_color/tests/unit/c/test-color-save_5.h +++ b/level_0/f_color/tests/unit/c/test-color-save_5.h @@ -17,9 +17,7 @@ * * @see f_color_save_5() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_color_save_5_parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_color_save_5_parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_color/tests/unit/c/test-color.c b/level_0/f_color/tests/unit/c/test-color.c index b3c70b3..859412b 100644 --- a/level_0/f_color/tests/unit/c/test-color.c +++ b/level_0/f_color/tests/unit/c/test-color.c @@ -20,22 +20,16 @@ int main(void) { const struct CMUnitTest tests[] = { - // f_color_load_context() only returns failures by other functions that have their own tests. cmocka_unit_test(test__f_color_load_context__works), - // f_color_save_1() only returns failures by other functions that have their own tests. cmocka_unit_test(test__f_color_save_1_works), - // f_color_save_2() only returns failures by other functions that have their own tests. cmocka_unit_test(test__f_color_save_2_works), - // f_color_save_3() only returns failures by other functions that have their own tests. cmocka_unit_test(test__f_color_save_3_works), - // f_color_save_4() only returns failures by other functions that have their own tests. cmocka_unit_test(test__f_color_save_4_works), - // f_color_save_5() only returns failures by other functions that have their own tests. cmocka_unit_test(test__f_color_save_5_works), cmocka_unit_test(test__f_color_context_delete__frees_memory), diff --git a/level_0/f_console/tests/unit/c/test-console-environment_process.c b/level_0/f_console/tests/unit/c/test-console-environment_process.c index 0ad0ce8..e959e10 100644 --- a/level_0/f_console/tests/unit/c/test-console-environment_process.c +++ b/level_0/f_console/tests/unit/c/test-console-environment_process.c @@ -27,18 +27,16 @@ void test__f_console_environment_process__data_not(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_console_environment_process__parameter_checking(void **state) { +void test__f_console_environment_process__parameter_checking(void **state) { - const f_console_arguments_t arguments = f_console_arguments_t_initialize; + const f_console_arguments_t arguments = f_console_arguments_t_initialize; - { - const f_status_t status = f_console_environment_process(arguments, 0); + { + const f_status_t status = f_console_environment_process(arguments, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_console_environment_process__works(void **state) { diff --git a/level_0/f_console/tests/unit/c/test-console-environment_process.h b/level_0/f_console/tests/unit/c/test-console-environment_process.h index 35a8e50..1c9b1b3 100644 --- a/level_0/f_console/tests/unit/c/test-console-environment_process.h +++ b/level_0/f_console/tests/unit/c/test-console-environment_process.h @@ -24,9 +24,7 @@ extern void test__f_console_environment_process__data_not(void **state); * * @see f_console_environment_process() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_console_environment_process__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_console_environment_process__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_console/tests/unit/c/test-console-identify.c b/level_0/f_console/tests/unit/c/test-console-identify.c index 03515fa..07dae40 100644 --- a/level_0/f_console/tests/unit/c/test-console-identify.c +++ b/level_0/f_console/tests/unit/c/test-console-identify.c @@ -5,18 +5,16 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_console_identify__parameter_checking(void **state) { +void test__f_console_identify__parameter_checking(void **state) { - const f_string_t input = f_string_t_initialize; + const f_string_t input = f_string_t_initialize; - { - const f_status_t status = f_console_identify(input, 0); + { + const f_status_t status = f_console_identify(input, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_console_identify__works(void **state) { diff --git a/level_0/f_console/tests/unit/c/test-console-identify.h b/level_0/f_console/tests/unit/c/test-console-identify.h index 11d6ec1..4aa9ba8 100644 --- a/level_0/f_console/tests/unit/c/test-console-identify.h +++ b/level_0/f_console/tests/unit/c/test-console-identify.h @@ -17,9 +17,7 @@ * * @see f_console_identify() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_console_identify__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_console_identify__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_console/tests/unit/c/test-console-parameter_prioritize_left.c b/level_0/f_console/tests/unit/c/test-console-parameter_prioritize_left.c index fe09272..ff38833 100644 --- a/level_0/f_console/tests/unit/c/test-console-parameter_prioritize_left.c +++ b/level_0/f_console/tests/unit/c/test-console-parameter_prioritize_left.c @@ -29,30 +29,28 @@ void test__f_console_parameter_prioritize_left__fails(void **state) { f_console_parameters_delete(¶meters); } -#ifndef _di_level_0_parameter_checking_ - void test__f_console_parameter_prioritize_left__parameter_checking(void **state) { +void test__f_console_parameter_prioritize_left__parameter_checking(void **state) { - f_console_parameters_t parameters = f_console_parameters_t_initialize; - f_console_parameter_ids_t choices = f_console_parameter_ids_t_initialize; - - { - const f_status_t status = f_console_parameter_prioritize_left(parameters, choices, 0); + f_console_parameters_t parameters = f_console_parameters_t_initialize; + f_console_parameter_ids_t choices = f_console_parameter_ids_t_initialize; - assert_int_equal(status, F_status_set_error(F_parameter)); - } + { + const f_status_t status = f_console_parameter_prioritize_left(parameters, choices, 0); - { - f_console_parameter_id_t ids_array[1] = { f_console_parameter_id_t_initialize }; - choices.id = ids_array; + assert_int_equal(status, F_status_set_error(F_parameter)); + } - const f_status_t status = f_console_parameter_prioritize_left(parameters, choices, 0); + { + f_console_parameter_id_t ids_array[1] = { f_console_parameter_id_t_initialize }; + choices.id = ids_array; - assert_int_equal(status, F_status_set_error(F_parameter)); - } + const f_status_t status = f_console_parameter_prioritize_left(parameters, choices, 0); - f_console_parameters_delete(¶meters); + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ + + f_console_parameters_delete(¶meters); +} void test__f_console_parameter_prioritize_left__works(void **state) { diff --git a/level_0/f_console/tests/unit/c/test-console-parameter_prioritize_left.h b/level_0/f_console/tests/unit/c/test-console-parameter_prioritize_left.h index 609ffae..371c13f 100644 --- a/level_0/f_console/tests/unit/c/test-console-parameter_prioritize_left.h +++ b/level_0/f_console/tests/unit/c/test-console-parameter_prioritize_left.h @@ -22,9 +22,7 @@ extern void test__f_console_parameter_prioritize_left__fails(void **state); * * @see f_console_parameter_prioritize_left() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_console_parameter_prioritize_left__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_console_parameter_prioritize_left__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_console/tests/unit/c/test-console-parameter_prioritize_right.c b/level_0/f_console/tests/unit/c/test-console-parameter_prioritize_right.c index 97917d9..9e01860 100644 --- a/level_0/f_console/tests/unit/c/test-console-parameter_prioritize_right.c +++ b/level_0/f_console/tests/unit/c/test-console-parameter_prioritize_right.c @@ -29,30 +29,28 @@ void test__f_console_parameter_prioritize_right__fails(void **state) { f_console_parameters_delete(¶meters); } -#ifndef _di_level_0_parameter_checking_ - void test__f_console_parameter_prioritize_right__parameter_checking(void **state) { +void test__f_console_parameter_prioritize_right__parameter_checking(void **state) { - f_console_parameters_t parameters = f_console_parameters_t_initialize; - f_console_parameter_ids_t choices = f_console_parameter_ids_t_initialize; - - { - const f_status_t status = f_console_parameter_prioritize_right(parameters, choices, 0); + f_console_parameters_t parameters = f_console_parameters_t_initialize; + f_console_parameter_ids_t choices = f_console_parameter_ids_t_initialize; - assert_int_equal(status, F_status_set_error(F_parameter)); - } + { + const f_status_t status = f_console_parameter_prioritize_right(parameters, choices, 0); - { - f_console_parameter_id_t ids_array[1] = { f_console_parameter_id_t_initialize }; - choices.id = ids_array; + assert_int_equal(status, F_status_set_error(F_parameter)); + } - const f_status_t status = f_console_parameter_prioritize_right(parameters, choices, 0); + { + f_console_parameter_id_t ids_array[1] = { f_console_parameter_id_t_initialize }; + choices.id = ids_array; - assert_int_equal(status, F_status_set_error(F_parameter)); - } + const f_status_t status = f_console_parameter_prioritize_right(parameters, choices, 0); - f_console_parameters_delete(¶meters); + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ + + f_console_parameters_delete(¶meters); +} void test__f_console_parameter_prioritize_right__works(void **state) { diff --git a/level_0/f_console/tests/unit/c/test-console-parameter_prioritize_right.h b/level_0/f_console/tests/unit/c/test-console-parameter_prioritize_right.h index 156bc59..597b1a6 100644 --- a/level_0/f_console/tests/unit/c/test-console-parameter_prioritize_right.h +++ b/level_0/f_console/tests/unit/c/test-console-parameter_prioritize_right.h @@ -22,9 +22,7 @@ extern void test__f_console_parameter_prioritize_right__fails(void **state); * * @see f_console_parameter_prioritize_right() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_console_parameter_prioritize_right__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_console_parameter_prioritize_right__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_console/tests/unit/c/test-console-parameter_process.c b/level_0/f_console/tests/unit/c/test-console-parameter_process.c index 641f23f..b43f48e 100644 --- a/level_0/f_console/tests/unit/c/test-console-parameter_process.c +++ b/level_0/f_console/tests/unit/c/test-console-parameter_process.c @@ -370,18 +370,16 @@ void test__f_console_parameter_process__only_remaining(void **state) { f_console_parameters_delete(¶meters); } -#ifndef _di_level_0_parameter_checking_ - void test__f_console_parameter_process__parameter_checking(void **state) { +void test__f_console_parameter_process__parameter_checking(void **state) { - const f_console_arguments_t arguments = f_console_arguments_t_initialize; + const f_console_arguments_t arguments = f_console_arguments_t_initialize; - { - const f_status_t status = f_console_parameter_process(arguments, 0); + { + const f_status_t status = f_console_parameter_process(arguments, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_console_parameter_process__works(void **state) { diff --git a/level_0/f_console/tests/unit/c/test-console-parameter_process.h b/level_0/f_console/tests/unit/c/test-console-parameter_process.h index 5e9c172..5151811 100644 --- a/level_0/f_console/tests/unit/c/test-console-parameter_process.h +++ b/level_0/f_console/tests/unit/c/test-console-parameter_process.h @@ -45,9 +45,7 @@ extern void test__f_console_parameter_process__only_remaining(void **state); * * @see f_console_parameter_process() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_console_parameter_process__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_console_parameter_process__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_console/tests/unit/c/test-console-parameters_delete.c b/level_0/f_console/tests/unit/c/test-console-parameters_delete.c index 9129cb0..2f1ac32 100644 --- a/level_0/f_console/tests/unit/c/test-console-parameters_delete.c +++ b/level_0/f_console/tests/unit/c/test-console-parameters_delete.c @@ -50,16 +50,14 @@ void test__f_console_parameters_delete__frees_memory(void **state) { } } -#ifndef _di_level_0_parameter_checking_ - void test__f_console_parameters_delete__parameter_checking(void **state) { +void test__f_console_parameters_delete__parameter_checking(void **state) { - { - const f_status_t status = f_console_parameters_delete(0); + { + const f_status_t status = f_console_parameters_delete(0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} #ifdef __cplusplus } // extern "C" diff --git a/level_0/f_console/tests/unit/c/test-console-parameters_delete.h b/level_0/f_console/tests/unit/c/test-console-parameters_delete.h index b15c282..b251375 100644 --- a/level_0/f_console/tests/unit/c/test-console-parameters_delete.h +++ b/level_0/f_console/tests/unit/c/test-console-parameters_delete.h @@ -22,8 +22,6 @@ extern void test__f_console_parameters_delete__frees_memory(void **state); * * @see f_console_parameters_delete() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_console_parameters_delete__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_console_parameters_delete__parameter_checking(void **state); #endif // _TEST__F_console__delete diff --git a/level_0/f_console/tests/unit/c/test-console-parameters_destroy.c b/level_0/f_console/tests/unit/c/test-console-parameters_destroy.c index 8254018..527dbbf 100644 --- a/level_0/f_console/tests/unit/c/test-console-parameters_destroy.c +++ b/level_0/f_console/tests/unit/c/test-console-parameters_destroy.c @@ -50,16 +50,14 @@ void test__f_console_parameters_destroy__frees_memory(void **state) { } } -#ifndef _di_level_0_parameter_checking_ - void test__f_console_parameters_destroy__parameter_checking(void **state) { +void test__f_console_parameters_destroy__parameter_checking(void **state) { - { - const f_status_t status = f_console_parameters_destroy(0); + { + const f_status_t status = f_console_parameters_destroy(0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} #ifdef __cplusplus } // extern "C" diff --git a/level_0/f_console/tests/unit/c/test-console-parameters_destroy.h b/level_0/f_console/tests/unit/c/test-console-parameters_destroy.h index 588e561..48c8a9b 100644 --- a/level_0/f_console/tests/unit/c/test-console-parameters_destroy.h +++ b/level_0/f_console/tests/unit/c/test-console-parameters_destroy.h @@ -22,8 +22,6 @@ extern void test__f_console_parameters_destroy__frees_memory(void **state); * * @see f_console_parameters_destroy() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_console_parameters_destroy__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_console_parameters_destroy__parameter_checking(void **state); #endif // _TEST__F_console__destroy diff --git a/level_0/f_console/tests/unit/c/test-console.c b/level_0/f_console/tests/unit/c/test-console.c index 07b59aa..055d99e 100644 --- a/level_0/f_console/tests/unit/c/test-console.c +++ b/level_0/f_console/tests/unit/c/test-console.c @@ -20,11 +20,9 @@ int main(void) { const struct CMUnitTest tests[] = { - // f_console_environment_process() only returns memory failures. cmocka_unit_test(test__f_console_environment_process__data_not), cmocka_unit_test(test__f_console_environment_process__works), - // f_console_identify() doesn't return failure. cmocka_unit_test(test__f_console_identify__works), cmocka_unit_test(test__f_console_parameter_prioritize_left__fails), @@ -33,7 +31,6 @@ int main(void) { cmocka_unit_test(test__f_console_parameter_prioritize_right__fails), cmocka_unit_test(test__f_console_parameter_prioritize_right__works), - // f_console_parameter_process() only returns memory failures. cmocka_unit_test(test__f_console_parameter_process__no_arguments_no_program), cmocka_unit_test(test__f_console_parameter_process__no_arguments), cmocka_unit_test(test__f_console_parameter_process__null_arguments), diff --git a/level_0/f_control_group/tests/unit/c/test-control_group-copy.c b/level_0/f_control_group/tests/unit/c/test-control_group-copy.c index 6be257a..17cd086 100644 --- a/level_0/f_control_group/tests/unit/c/test-control_group-copy.c +++ b/level_0/f_control_group/tests/unit/c/test-control_group-copy.c @@ -5,18 +5,16 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_control_group_copy__parameter_checking(void **state) { +void test__f_control_group_copy__parameter_checking(void **state) { - const f_control_group_t source = f_control_group_t_initialize; + const f_control_group_t source = f_control_group_t_initialize; - { - const f_status_t status = f_control_group_copy(source, 0); + { + const f_status_t status = f_control_group_copy(source, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_control_group_copy__works(void **state) { diff --git a/level_0/f_control_group/tests/unit/c/test-control_group-copy.h b/level_0/f_control_group/tests/unit/c/test-control_group-copy.h index eeff77a..806db5e 100644 --- a/level_0/f_control_group/tests/unit/c/test-control_group-copy.h +++ b/level_0/f_control_group/tests/unit/c/test-control_group-copy.h @@ -17,9 +17,7 @@ * * @see f_control_group_copy() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_control_group_copy__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_control_group_copy__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_control_group/tests/unit/c/test-control_group.c b/level_0/f_control_group/tests/unit/c/test-control_group.c index c295aa2..574f6f6 100644 --- a/level_0/f_control_group/tests/unit/c/test-control_group.c +++ b/level_0/f_control_group/tests/unit/c/test-control_group.c @@ -20,7 +20,6 @@ int main(void) { const struct CMUnitTest tests[] = { - // f_control_group_copy() only returns memory failures. cmocka_unit_test(test__f_control_group_copy__works), #ifndef _di_level_0_parameter_checking_ diff --git a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_binary.c b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_binary.c index 7fe6b7a..51aae96 100644 --- a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_binary.c +++ b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_binary.c @@ -28,16 +28,14 @@ void test__f_conversion_character_to_binary__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_conversion_character_to_binary__parameter_checking(void **state) { +void test__f_conversion_character_to_binary__parameter_checking(void **state) { - { - const f_status_t status = f_conversion_character_to_binary(0, 0); + { + const f_status_t status = f_conversion_character_to_binary(0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_conversion_character_to_binary__works(void **state) { diff --git a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_binary.h b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_binary.h index 485d090..68b8f65 100644 --- a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_binary.h +++ b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_binary.h @@ -22,9 +22,7 @@ extern void test__f_conversion_character_to_binary__fails(void **state); * * @see f_conversion_character_to_binary() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_conversion_character_to_binary__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_conversion_character_to_binary__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_decimal.c b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_decimal.c index 6c9ee0f..a842adc 100644 --- a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_decimal.c +++ b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_decimal.c @@ -36,16 +36,14 @@ void test__f_conversion_character_to_decimal__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_conversion_character_to_decimal__parameter_checking(void **state) { +void test__f_conversion_character_to_decimal__parameter_checking(void **state) { - { - const f_status_t status = f_conversion_character_to_decimal(0, 0); + { + const f_status_t status = f_conversion_character_to_decimal(0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_conversion_character_to_decimal__works(void **state) { diff --git a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_decimal.h b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_decimal.h index 57de425..501e8de 100644 --- a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_decimal.h +++ b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_decimal.h @@ -22,9 +22,7 @@ extern void test__f_conversion_character_to_decimal__fails(void **state); * * @see f_conversion_character_to_decimal() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_conversion_character_to_decimal__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_conversion_character_to_decimal__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_duodecimal.c b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_duodecimal.c index e78a5ef..a335e66 100644 --- a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_duodecimal.c +++ b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_duodecimal.c @@ -40,16 +40,14 @@ void test__f_conversion_character_to_duodecimal__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_conversion_character_to_duodecimal__parameter_checking(void **state) { +void test__f_conversion_character_to_duodecimal__parameter_checking(void **state) { - { - const f_status_t status = f_conversion_character_to_duodecimal(0, 0); + { + const f_status_t status = f_conversion_character_to_duodecimal(0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_conversion_character_to_duodecimal__works(void **state) { diff --git a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_duodecimal.h b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_duodecimal.h index dc43c75..5d760d8 100644 --- a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_duodecimal.h +++ b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_duodecimal.h @@ -22,9 +22,7 @@ extern void test__f_conversion_character_to_duodecimal__fails(void **state); * * @see f_conversion_character_to_duodecimal() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_conversion_character_to_duodecimal__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_conversion_character_to_duodecimal__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_hexidecimal.c b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_hexidecimal.c index 4e7f7d8..5ba8fa5 100644 --- a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_hexidecimal.c +++ b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_hexidecimal.c @@ -48,16 +48,14 @@ void test__f_conversion_character_to_hexidecimal__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_conversion_character_to_hexidecimal__parameter_checking(void **state) { +void test__f_conversion_character_to_hexidecimal__parameter_checking(void **state) { - { - const f_status_t status = f_conversion_character_to_hexidecimal(0, 0); + { + const f_status_t status = f_conversion_character_to_hexidecimal(0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_conversion_character_to_hexidecimal__works(void **state) { diff --git a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_hexidecimal.h b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_hexidecimal.h index 8e07d0a..59b4b6c 100644 --- a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_hexidecimal.h +++ b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_hexidecimal.h @@ -22,9 +22,7 @@ extern void test__f_conversion_character_to_hexidecimal__fails(void **state); * * @see f_conversion_character_to_hexidecimal() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_conversion_character_to_hexidecimal__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_conversion_character_to_hexidecimal__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_octal.c b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_octal.c index 6c9fcb4..5257b7e 100644 --- a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_octal.c +++ b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_octal.c @@ -34,16 +34,14 @@ void test__f_conversion_character_to_octal__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_conversion_character_to_octal__parameter_checking(void **state) { +void test__f_conversion_character_to_octal__parameter_checking(void **state) { - { - const f_status_t status = f_conversion_character_to_octal(0, 0); + { + const f_status_t status = f_conversion_character_to_octal(0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_conversion_character_to_octal__works(void **state) { diff --git a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_octal.h b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_octal.h index 041b15e..c1faac4 100644 --- a/level_0/f_conversion/tests/unit/c/test-conversion-character_to_octal.h +++ b/level_0/f_conversion/tests/unit/c/test-conversion-character_to_octal.h @@ -22,9 +22,7 @@ extern void test__f_conversion_character_to_octal__fails(void **state); * * @see f_conversion_character_to_octal() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_conversion_character_to_octal__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_conversion_character_to_octal__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_conversion/tests/unit/c/test-conversion-number_signed_print.c b/level_0/f_conversion/tests/unit/c/test-conversion-number_signed_print.c index e3258a8..db89218 100644 --- a/level_0/f_conversion/tests/unit/c/test-conversion-number_signed_print.c +++ b/level_0/f_conversion/tests/unit/c/test-conversion-number_signed_print.c @@ -47,27 +47,25 @@ void test__f_conversion_number_signed_print__fails_for_zero(void **state) { } } -#ifndef _di_level_0_parameter_checking_ - void test__f_conversion_number_signed_print__parameter_checking(void **state) { +void test__f_conversion_number_signed_print__parameter_checking(void **state) { - { - const f_conversion_data_t data = macro_f_conversion_data_t_initialize(2, 0, 0); + { + const f_conversion_data_t data = macro_f_conversion_data_t_initialize(2, 0, 0); - const f_status_t status = f_conversion_number_signed_print(0, data, 0); + const f_status_t status = f_conversion_number_signed_print(0, data, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); + } - { - FILE *file = 0; - const f_conversion_data_t data = macro_f_conversion_data_t_initialize(1, 0, 0); + { + FILE *file = 0; + const f_conversion_data_t data = macro_f_conversion_data_t_initialize(1, 0, 0); - const f_status_t status = f_conversion_number_signed_print(0, data, file); + const f_status_t status = f_conversion_number_signed_print(0, data, file); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_conversion_number_signed_print__works(void **state) { diff --git a/level_0/f_conversion/tests/unit/c/test-conversion-number_signed_print.h b/level_0/f_conversion/tests/unit/c/test-conversion-number_signed_print.h index 0c9ed82..2dacb4d 100644 --- a/level_0/f_conversion/tests/unit/c/test-conversion-number_signed_print.h +++ b/level_0/f_conversion/tests/unit/c/test-conversion-number_signed_print.h @@ -36,9 +36,7 @@ extern void test__f_conversion_number_signed_print__fails_for_zero(void **state) * * @see f_conversion_number_signed_print() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_conversion_number_signed_print__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_conversion_number_signed_print__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_conversion/tests/unit/c/test-conversion-number_signed_to_string.c b/level_0/f_conversion/tests/unit/c/test-conversion-number_signed_to_string.c index 5ebdd0c..1baf68f 100644 --- a/level_0/f_conversion/tests/unit/c/test-conversion-number_signed_to_string.c +++ b/level_0/f_conversion/tests/unit/c/test-conversion-number_signed_to_string.c @@ -5,27 +5,25 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_conversion_number_signed_to_string__parameter_checking(void **state) { +void test__f_conversion_number_signed_to_string__parameter_checking(void **state) { - { - const f_conversion_data_t data = macro_f_conversion_data_t_initialize(2, 0, 0); + { + const f_conversion_data_t data = macro_f_conversion_data_t_initialize(2, 0, 0); - const f_status_t status = f_conversion_number_signed_to_string(0, data, 0); + const f_status_t status = f_conversion_number_signed_to_string(0, data, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); + } - { - f_string_dynamic_t string; - const f_conversion_data_t data = macro_f_conversion_data_t_initialize(1, 0, 0); + { + f_string_dynamic_t string; + const f_conversion_data_t data = macro_f_conversion_data_t_initialize(1, 0, 0); - const f_status_t status = f_conversion_number_signed_to_string(0, data, &string); + const f_status_t status = f_conversion_number_signed_to_string(0, data, &string); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_conversion_number_signed_to_string__works(void **state) { diff --git a/level_0/f_conversion/tests/unit/c/test-conversion-number_signed_to_string.h b/level_0/f_conversion/tests/unit/c/test-conversion-number_signed_to_string.h index f3c9c90..44a1eb7 100644 --- a/level_0/f_conversion/tests/unit/c/test-conversion-number_signed_to_string.h +++ b/level_0/f_conversion/tests/unit/c/test-conversion-number_signed_to_string.h @@ -17,9 +17,7 @@ * * @see f_conversion_number_signed_to_string() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_conversion_number_signed_to_string__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_conversion_number_signed_to_string__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_conversion/tests/unit/c/test-conversion-number_unsigned_print.c b/level_0/f_conversion/tests/unit/c/test-conversion-number_unsigned_print.c index 6d3208c..a9df510 100644 --- a/level_0/f_conversion/tests/unit/c/test-conversion-number_unsigned_print.c +++ b/level_0/f_conversion/tests/unit/c/test-conversion-number_unsigned_print.c @@ -47,27 +47,25 @@ void test__f_conversion_number_unsigned_print__fails_for_zero(void **state) { } } -#ifndef _di_level_0_parameter_checking_ - void test__f_conversion_number_unsigned_print__parameter_checking(void **state) { +void test__f_conversion_number_unsigned_print__parameter_checking(void **state) { - { - const f_conversion_data_t data = macro_f_conversion_data_t_initialize(2, 0, 0); + { + const f_conversion_data_t data = macro_f_conversion_data_t_initialize(2, 0, 0); - const f_status_t status = f_conversion_number_unsigned_print(0, data, 0); + const f_status_t status = f_conversion_number_unsigned_print(0, data, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); + } - { - FILE *file = 0; - const f_conversion_data_t data = macro_f_conversion_data_t_initialize(1, 0, 0); + { + FILE *file = 0; + const f_conversion_data_t data = macro_f_conversion_data_t_initialize(1, 0, 0); - const f_status_t status = f_conversion_number_unsigned_print(0, data, file); + const f_status_t status = f_conversion_number_unsigned_print(0, data, file); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_conversion_number_unsigned_print__works(void **state) { diff --git a/level_0/f_conversion/tests/unit/c/test-conversion-number_unsigned_print.h b/level_0/f_conversion/tests/unit/c/test-conversion-number_unsigned_print.h index cb8e365..65c6e1a 100644 --- a/level_0/f_conversion/tests/unit/c/test-conversion-number_unsigned_print.h +++ b/level_0/f_conversion/tests/unit/c/test-conversion-number_unsigned_print.h @@ -36,9 +36,7 @@ extern void test__f_conversion_number_unsigned_print__fails_for_zero(void **stat * * @see f_conversion_number_unsigned_print() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_conversion_number_unsigned_print__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_conversion_number_unsigned_print__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_conversion/tests/unit/c/test-conversion-number_unsigned_to_string.c b/level_0/f_conversion/tests/unit/c/test-conversion-number_unsigned_to_string.c index 338a420..a7879fb 100644 --- a/level_0/f_conversion/tests/unit/c/test-conversion-number_unsigned_to_string.c +++ b/level_0/f_conversion/tests/unit/c/test-conversion-number_unsigned_to_string.c @@ -5,27 +5,25 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_conversion_number_unsigned_to_string__parameter_checking(void **state) { +void test__f_conversion_number_unsigned_to_string__parameter_checking(void **state) { - { - const f_conversion_data_t data = macro_f_conversion_data_t_initialize(2, 0, 0); + { + const f_conversion_data_t data = macro_f_conversion_data_t_initialize(2, 0, 0); - const f_status_t status = f_conversion_number_unsigned_to_string(0, data, 0); + const f_status_t status = f_conversion_number_unsigned_to_string(0, data, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); + } - { - f_string_dynamic_t string; - const f_conversion_data_t data = macro_f_conversion_data_t_initialize(1, 0, 0); + { + f_string_dynamic_t string; + const f_conversion_data_t data = macro_f_conversion_data_t_initialize(1, 0, 0); - const f_status_t status = f_conversion_number_unsigned_to_string(0, data, &string); + const f_status_t status = f_conversion_number_unsigned_to_string(0, data, &string); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_conversion_number_unsigned_to_string__works(void **state) { diff --git a/level_0/f_conversion/tests/unit/c/test-conversion-number_unsigned_to_string.h b/level_0/f_conversion/tests/unit/c/test-conversion-number_unsigned_to_string.h index 8c16f89..904ff84 100644 --- a/level_0/f_conversion/tests/unit/c/test-conversion-number_unsigned_to_string.h +++ b/level_0/f_conversion/tests/unit/c/test-conversion-number_unsigned_to_string.h @@ -17,9 +17,7 @@ * * @see f_conversion_number_unsigned_to_string() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_conversion_number_unsigned_to_string__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_conversion_number_unsigned_to_string__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_conversion/tests/unit/c/test-conversion.c b/level_0/f_conversion/tests/unit/c/test-conversion.c index 2528f95..9edfce2 100644 --- a/level_0/f_conversion/tests/unit/c/test-conversion.c +++ b/level_0/f_conversion/tests/unit/c/test-conversion.c @@ -20,19 +20,14 @@ int main(void) { const struct CMUnitTest tests[] = { - // f_conversion_character_is_binary() doesn't return failure. cmocka_unit_test(test__f_conversion_character_is_binary__works), - // f_conversion_character_is_decimal() doesn't return failure. cmocka_unit_test(test__f_conversion_character_is_decimal__works), - // f_conversion_character_is_duodecimal() doesn't return failure. cmocka_unit_test(test__f_conversion_character_is_duodecimal__works), - // f_conversion_character_is_hexidecimal() doesn't return failure. cmocka_unit_test(test__f_conversion_character_is_hexidecimal__works), - // f_conversion_character_is_octal() doesn't return failure. cmocka_unit_test(test__f_conversion_character_is_octal__works), cmocka_unit_test(test__f_conversion_character_to_binary__fails), @@ -56,7 +51,6 @@ int main(void) { //cmocka_unit_test(test__f_conversion_number_signed_print__fails_for_zero), //cmocka_unit_test(test__f_conversion_number_signed_print__works), - // f_conversion_number_signed_to_string() only returns memory failures. cmocka_unit_test(test__f_conversion_number_signed_to_string__works), cmocka_unit_test(test__f_conversion_number_signed_to_string__works_for_prepend), cmocka_unit_test(test__f_conversion_number_signed_to_string__works_for_zero), @@ -67,7 +61,6 @@ int main(void) { //cmocka_unit_test(test__f_conversion_number_unsigned_print__fails_for_zero), //cmocka_unit_test(test__f_conversion_number_unsigned_print__works), - // f_conversion_number_unsigned_to_string() only returns memory failures. cmocka_unit_test(test__f_conversion_number_unsigned_to_string__works), cmocka_unit_test(test__f_conversion_number_unsigned_to_string__works_for_prepend), cmocka_unit_test(test__f_conversion_number_unsigned_to_string__works_for_zero), diff --git a/level_0/f_directory/tests/unit/c/test-directory-list.c b/level_0/f_directory/tests/unit/c/test-directory-list.c index a8b7c4d..3f5047d 100644 --- a/level_0/f_directory/tests/unit/c/test-directory-list.c +++ b/level_0/f_directory/tests/unit/c/test-directory-list.c @@ -37,18 +37,16 @@ void test__f_directory_list__fails(void **state) { f_string_dynamics_resize(0, &names); } -#ifndef _di_level_0_parameter_checking_ - void test__f_directory_list__parameter_checking(void **state) { +void test__f_directory_list__parameter_checking(void **state) { - const f_string_static_t path = macro_f_string_static_t_initialize("test", 0, 4); + const f_string_static_t path = macro_f_string_static_t_initialize("test", 0, 4); - { - const f_status_t status = f_directory_list(path, 0, 0, 0); + { + const f_status_t status = f_directory_list(path, 0, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_directory_list__returns_data_not(void **state) { diff --git a/level_0/f_directory/tests/unit/c/test-directory-list.h b/level_0/f_directory/tests/unit/c/test-directory-list.h index e79f07d..fbc08a0 100644 --- a/level_0/f_directory/tests/unit/c/test-directory-list.h +++ b/level_0/f_directory/tests/unit/c/test-directory-list.h @@ -22,9 +22,7 @@ extern void test__f_directory_list__fails(void **state); * * @see f_directory_list() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_directory_list__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_directory_list__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_directory/tests/unit/c/test-directory-open.c b/level_0/f_directory/tests/unit/c/test-directory-open.c index 0fb1c0f..c6d7ff4 100644 --- a/level_0/f_directory/tests/unit/c/test-directory-open.c +++ b/level_0/f_directory/tests/unit/c/test-directory-open.c @@ -60,18 +60,16 @@ void test__f_directory_open__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_directory_open__parameter_checking(void **state) { +void test__f_directory_open__parameter_checking(void **state) { - const f_string_static_t path = macro_f_string_static_t_initialize("test", 0, 4); + const f_string_static_t path = macro_f_string_static_t_initialize("test", 0, 4); - { - const f_status_t status = f_directory_open(path, 0, 0); + { + const f_status_t status = f_directory_open(path, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_directory_open__returns_data_not(void **state) { diff --git a/level_0/f_directory/tests/unit/c/test-directory-open.h b/level_0/f_directory/tests/unit/c/test-directory-open.h index d625e14..5efe2cd 100644 --- a/level_0/f_directory/tests/unit/c/test-directory-open.h +++ b/level_0/f_directory/tests/unit/c/test-directory-open.h @@ -22,9 +22,7 @@ extern void test__f_directory_open__fails(void **state); * * @see f_directory_open() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_directory_open__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_directory_open__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_directory/tests/unit/c/test-directory-open_at.c b/level_0/f_directory/tests/unit/c/test-directory-open_at.c index bffb3b6..5220794 100644 --- a/level_0/f_directory/tests/unit/c/test-directory-open_at.c +++ b/level_0/f_directory/tests/unit/c/test-directory-open_at.c @@ -63,18 +63,16 @@ void test__f_directory_open_at__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_directory_open_at__parameter_checking(void **state) { +void test__f_directory_open_at__parameter_checking(void **state) { - const f_string_static_t path = macro_f_string_static_t_initialize("test", 0, 4); + const f_string_static_t path = macro_f_string_static_t_initialize("test", 0, 4); - { - const f_status_t status = f_directory_open_at(0, path, 0, 0); + { + const f_status_t status = f_directory_open_at(0, path, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_directory_open_at__returns_data_not(void **state) { diff --git a/level_0/f_directory/tests/unit/c/test-directory-open_at.h b/level_0/f_directory/tests/unit/c/test-directory-open_at.h index 410e749..18b7e1a 100644 --- a/level_0/f_directory/tests/unit/c/test-directory-open_at.h +++ b/level_0/f_directory/tests/unit/c/test-directory-open_at.h @@ -22,9 +22,7 @@ extern void test__f_directory_open_at__fails(void **state); * * @see f_directory_open_at() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_directory_open_at__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_directory_open_at__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_directory/tests/unit/c/test-directory-remove.c b/level_0/f_directory/tests/unit/c/test-directory-remove.c index d6511ed..07d8111 100644 --- a/level_0/f_directory/tests/unit/c/test-directory-remove.c +++ b/level_0/f_directory/tests/unit/c/test-directory-remove.c @@ -88,18 +88,16 @@ void test__f_directory_remove__fails(void **state) { } } -#ifndef _di_level_0_parameter_checking_ - void test__f_directory_remove__parameter_checking(void **state) { +void test__f_directory_remove__parameter_checking(void **state) { - const f_string_static_t path = macro_f_string_static_t_initialize("test", 0, 4); + const f_string_static_t path = macro_f_string_static_t_initialize("test", 0, 4); - { - const f_status_t status = f_directory_remove(path, -1, 0); + { + const f_status_t status = f_directory_remove(path, -1, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_directory_remove__returns_data_not(void **state) { diff --git a/level_0/f_directory/tests/unit/c/test-directory-remove.h b/level_0/f_directory/tests/unit/c/test-directory-remove.h index d8dd9fa..c8d2928 100644 --- a/level_0/f_directory/tests/unit/c/test-directory-remove.h +++ b/level_0/f_directory/tests/unit/c/test-directory-remove.h @@ -22,9 +22,7 @@ extern void test__f_directory_remove__fails(void **state); * * @see f_directory_remove() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_directory_remove__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_directory_remove__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_directory/tests/unit/c/test-directory-remove_custom.c b/level_0/f_directory/tests/unit/c/test-directory-remove_custom.c index fd52c3e..f7503cd 100644 --- a/level_0/f_directory/tests/unit/c/test-directory-remove_custom.c +++ b/level_0/f_directory/tests/unit/c/test-directory-remove_custom.c @@ -88,18 +88,16 @@ void test__f_directory_remove_custom__fails(void **state) { } } -#ifndef _di_level_0_parameter_checking_ - void test__f_directory_remove_custom__parameter_checking(void **state) { +void test__f_directory_remove_custom__parameter_checking(void **state) { - const f_string_static_t path = macro_f_string_static_t_initialize("test", 0, 4); + const f_string_static_t path = macro_f_string_static_t_initialize("test", 0, 4); - { - const f_status_t status = f_directory_remove_custom(path, -1, 0, 0); + { + const f_status_t status = f_directory_remove_custom(path, -1, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_directory_remove_custom__returns_data_not(void **state) { diff --git a/level_0/f_directory/tests/unit/c/test-directory-remove_custom.h b/level_0/f_directory/tests/unit/c/test-directory-remove_custom.h index 6ad2fc5..570b50c 100644 --- a/level_0/f_directory/tests/unit/c/test-directory-remove_custom.h +++ b/level_0/f_directory/tests/unit/c/test-directory-remove_custom.h @@ -22,9 +22,7 @@ extern void test__f_directory_remove_custom__fails(void **state); * * @see f_directory_remove_custom() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_directory_remove_custom__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_directory_remove_custom__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_environment/tests/unit/c/test-environment-get.c b/level_0/f_environment/tests/unit/c/test-environment-get.c index 90324ee..f8907f8 100644 --- a/level_0/f_environment/tests/unit/c/test-environment-get.c +++ b/level_0/f_environment/tests/unit/c/test-environment-get.c @@ -22,18 +22,16 @@ void test__f_environment_get__fails(void **state) { f_string_dynamic_resize(0, &buffer); } -#ifndef _di_level_0_parameter_checking_ - void test__f_environment_get__parameter_checking(void **state) { +void test__f_environment_get__parameter_checking(void **state) { - const f_string_static_t path = macro_f_string_static_t_initialize("test", 0, 4); + const f_string_static_t path = macro_f_string_static_t_initialize("test", 0, 4); - { - const f_status_t status = f_environment_get(path, 0); + { + const f_status_t status = f_environment_get(path, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_environment_get__returns_data_not(void **state) { diff --git a/level_0/f_environment/tests/unit/c/test-environment-get.h b/level_0/f_environment/tests/unit/c/test-environment-get.h index 32edb8e..dbd9891 100644 --- a/level_0/f_environment/tests/unit/c/test-environment-get.h +++ b/level_0/f_environment/tests/unit/c/test-environment-get.h @@ -22,9 +22,7 @@ extern void test__f_environment_get__fails(void **state); * * @see f_environment_get() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_environment_get__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_environment_get__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-close.c b/level_0/f_file/tests/unit/c/test-file-close.c index cb3c3a2..a0a4349 100644 --- a/level_0/f_file/tests/unit/c/test-file-close.c +++ b/level_0/f_file/tests/unit/c/test-file-close.c @@ -47,16 +47,14 @@ void test__f_file_close__fails(void **state) { } } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_close__parameter_checking(void **state) { +void test__f_file_close__parameter_checking(void **state) { - { - const f_status_t status = f_file_close(0); + { + const f_status_t status = f_file_close(0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_close__works(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-close.h b/level_0/f_file/tests/unit/c/test-file-close.h index 95d7740..4c0010d 100644 --- a/level_0/f_file/tests/unit/c/test-file-close.h +++ b/level_0/f_file/tests/unit/c/test-file-close.h @@ -22,9 +22,7 @@ extern void test__f_file_close__fails(void **state); * * @see f_file_close() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_close__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_close__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_file/tests/unit/c/test-file-close_flush.c b/level_0/f_file/tests/unit/c/test-file-close_flush.c index 0825517..fc7f370 100644 --- a/level_0/f_file/tests/unit/c/test-file-close_flush.c +++ b/level_0/f_file/tests/unit/c/test-file-close_flush.c @@ -50,16 +50,14 @@ void test__f_file_close_flush__fails(void **state) { } } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_close_flush__parameter_checking(void **state) { +void test__f_file_close_flush__parameter_checking(void **state) { - { - const f_status_t status = f_file_close_flush(0); + { + const f_status_t status = f_file_close_flush(0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_close_flush__works(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-close_flush.h b/level_0/f_file/tests/unit/c/test-file-close_flush.h index cdcbad4..09b3bfa 100644 --- a/level_0/f_file/tests/unit/c/test-file-close_flush.h +++ b/level_0/f_file/tests/unit/c/test-file-close_flush.h @@ -22,9 +22,7 @@ extern void test__f_file_close_flush__fails(void **state); * * @see f_file_close_flush() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_close_flush__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_close_flush__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_file/tests/unit/c/test-file-descriptor.c b/level_0/f_file/tests/unit/c/test-file-descriptor.c index 3be16fe..ba2d6bf 100644 --- a/level_0/f_file/tests/unit/c/test-file-descriptor.c +++ b/level_0/f_file/tests/unit/c/test-file-descriptor.c @@ -18,16 +18,14 @@ void test__f_file_descriptor__fails(void **state) { } } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_descriptor__parameter_checking(void **state) { +void test__f_file_descriptor__parameter_checking(void **state) { - { - const f_status_t status = f_file_descriptor(0); + { + const f_status_t status = f_file_descriptor(0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_descriptor__works(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-descriptor.h b/level_0/f_file/tests/unit/c/test-file-descriptor.h index 09e9a74..5f98cf8 100644 --- a/level_0/f_file/tests/unit/c/test-file-descriptor.h +++ b/level_0/f_file/tests/unit/c/test-file-descriptor.h @@ -22,9 +22,7 @@ extern void test__f_file_descriptor__fails(void **state); * * @see f_file_descriptor() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_descriptor__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_descriptor__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_file/tests/unit/c/test-file-group_read.c b/level_0/f_file/tests/unit/c/test-file-group_read.c index 04fdf5e..516de7c 100644 --- a/level_0/f_file/tests/unit/c/test-file-group_read.c +++ b/level_0/f_file/tests/unit/c/test-file-group_read.c @@ -46,16 +46,14 @@ void test__f_file_group_read__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_group_read__parameter_checking(void **state) { +void test__f_file_group_read__parameter_checking(void **state) { - { - const f_status_t status = f_file_group_read(f_string_empty_s, F_false, 0); + { + const f_status_t status = f_file_group_read(f_string_empty_s, F_false, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_group_read__returns_data_not(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-group_read.h b/level_0/f_file/tests/unit/c/test-file-group_read.h index ce36ca5..30fe034 100644 --- a/level_0/f_file/tests/unit/c/test-file-group_read.h +++ b/level_0/f_file/tests/unit/c/test-file-group_read.h @@ -22,9 +22,7 @@ extern void test__f_file_group_read__fails(void **state); * * @see f_file_group_read() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_group_read__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_group_read__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-link_read.c b/level_0/f_file/tests/unit/c/test-file-link_read.c index cf7fcb8..e2b381d 100644 --- a/level_0/f_file/tests/unit/c/test-file-link_read.c +++ b/level_0/f_file/tests/unit/c/test-file-link_read.c @@ -62,24 +62,22 @@ void test__f_file_link_read__fails(void **state) { f_string_dynamic_resize(0, &buffer); } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_link_read__parameter_checking(void **state) { +void test__f_file_link_read__parameter_checking(void **state) { - struct stat statistics; - - memset(&statistics, 0, sizeof(struct stat)); + struct stat statistics; - f_string_dynamic_t buffer = f_string_dynamic_t_initialize; + memset(&statistics, 0, sizeof(struct stat)); - { - const f_status_t status = f_file_link_read(f_string_empty_s, F_true, 0); + f_string_dynamic_t buffer = f_string_dynamic_t_initialize; - assert_int_equal(status, F_status_set_error(F_parameter)); - } + { + const f_status_t status = f_file_link_read(f_string_empty_s, F_true, 0); - f_string_dynamic_resize(0, &buffer); + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ + + f_string_dynamic_resize(0, &buffer); +} void test__f_file_link_read__returns_data_not(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-link_read.h b/level_0/f_file/tests/unit/c/test-file-link_read.h index f10a59a..d64c0f6 100644 --- a/level_0/f_file/tests/unit/c/test-file-link_read.h +++ b/level_0/f_file/tests/unit/c/test-file-link_read.h @@ -22,9 +22,7 @@ extern void test__f_file_link_read__fails(void **state); * * @see f_file_link_read() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_link_read__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_link_read__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-link_read_at.c b/level_0/f_file/tests/unit/c/test-file-link_read_at.c index f163ade..52c10ac 100644 --- a/level_0/f_file/tests/unit/c/test-file-link_read_at.c +++ b/level_0/f_file/tests/unit/c/test-file-link_read_at.c @@ -62,20 +62,18 @@ void test__f_file_link_read_at__fails(void **state) { f_string_dynamic_resize(0, &buffer); } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_link_read_at__parameter_checking(void **state) { +void test__f_file_link_read_at__parameter_checking(void **state) { - f_string_dynamic_t buffer = f_string_dynamic_t_initialize; - - { - const f_status_t status = f_file_link_read_at(0, f_string_empty_s, 0, 0); + f_string_dynamic_t buffer = f_string_dynamic_t_initialize; - assert_int_equal(status, F_status_set_error(F_parameter)); - } + { + const f_status_t status = f_file_link_read_at(0, f_string_empty_s, 0, 0); - f_string_dynamic_resize(0, &buffer); + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ + + f_string_dynamic_resize(0, &buffer); +} void test__f_file_link_read_at__returns_data_not(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-link_read_at.h b/level_0/f_file/tests/unit/c/test-file-link_read_at.h index e0e6a7c..6eb069b 100644 --- a/level_0/f_file/tests/unit/c/test-file-link_read_at.h +++ b/level_0/f_file/tests/unit/c/test-file-link_read_at.h @@ -22,9 +22,7 @@ extern void test__f_file_link_read_at__fails(void **state); * * @see f_file_link_read_at() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_link_read_at__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_link_read_at__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-mode_determine.c b/level_0/f_file/tests/unit/c/test-file-mode_determine.c index 1e57d82..cc9fe40 100644 --- a/level_0/f_file/tests/unit/c/test-file-mode_determine.c +++ b/level_0/f_file/tests/unit/c/test-file-mode_determine.c @@ -5,19 +5,17 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_file_mode_determine__parameter_checking(void **state) { +void test__f_file_mode_determine__parameter_checking(void **state) { - const mode_t mode_file = 0; - const f_file_mode_t mode_change = f_file_mode_t_initialize; + const mode_t mode_file = 0; + const f_file_mode_t mode_change = f_file_mode_t_initialize; - { - const f_status_t status = f_file_mode_determine(mode_file, mode_change, 0, F_false, 0); + { + const f_status_t status = f_file_mode_determine(mode_file, mode_change, 0, F_false, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_mode_determine__works_basic(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-mode_determine.h b/level_0/f_file/tests/unit/c/test-file-mode_determine.h index 2dd1def..36501cc 100644 --- a/level_0/f_file/tests/unit/c/test-file-mode_determine.h +++ b/level_0/f_file/tests/unit/c/test-file-mode_determine.h @@ -15,9 +15,7 @@ * * @see f_file_mode_determine() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_mode_determine__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_mode_determine__parameter_checking(void **state); /** * Test that function works for basic combinations. diff --git a/level_0/f_file/tests/unit/c/test-file-mode_from_string.c b/level_0/f_file/tests/unit/c/test-file-mode_from_string.c index 8128f29..0a084d1 100644 --- a/level_0/f_file/tests/unit/c/test-file-mode_from_string.c +++ b/level_0/f_file/tests/unit/c/test-file-mode_from_string.c @@ -194,32 +194,30 @@ void test__f_file_mode_from_string__fails_basic(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_mode_from_string__parameter_checking(void **state) { +void test__f_file_mode_from_string__parameter_checking(void **state) { - { - const f_status_t status = f_file_mode_from_string(f_string_empty_s, 0, 0, 0); + { + const f_status_t status = f_file_mode_from_string(f_string_empty_s, 0, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); + } - { - f_file_mode_t mode_file = f_file_mode_t_initialize; + { + f_file_mode_t mode_file = f_file_mode_t_initialize; - const f_status_t status = f_file_mode_from_string(f_string_empty_s, 0, &mode_file, 0); + const f_status_t status = f_file_mode_from_string(f_string_empty_s, 0, &mode_file, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); + } - { - uint8_t replace = 0; + { + uint8_t replace = 0; - const f_status_t status = f_file_mode_from_string(f_string_empty_s, 0, 0, &replace); + const f_status_t status = f_file_mode_from_string(f_string_empty_s, 0, 0, &replace); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_mode_from_string__returns_data_not(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-mode_from_string.h b/level_0/f_file/tests/unit/c/test-file-mode_from_string.h index a0a267f..1a0a9e5 100644 --- a/level_0/f_file/tests/unit/c/test-file-mode_from_string.h +++ b/level_0/f_file/tests/unit/c/test-file-mode_from_string.h @@ -22,9 +22,7 @@ extern void test__f_file_mode_from_string__fails_basic(void **state); * * @see f_file_mode_from_string() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_mode_from_string__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_mode_from_string__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-mode_read.c b/level_0/f_file/tests/unit/c/test-file-mode_read.c index 4380f5f..ec3872e 100644 --- a/level_0/f_file/tests/unit/c/test-file-mode_read.c +++ b/level_0/f_file/tests/unit/c/test-file-mode_read.c @@ -48,16 +48,14 @@ void test__f_file_mode_read__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_mode_read__parameter_checking(void **state) { +void test__f_file_mode_read__parameter_checking(void **state) { - { - const f_status_t status = f_file_mode_read(f_string_empty_s, F_true, 0); + { + const f_status_t status = f_file_mode_read(f_string_empty_s, F_true, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_mode_read__returns_data_not(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-mode_read.h b/level_0/f_file/tests/unit/c/test-file-mode_read.h index 0052f17..4a6fe41 100644 --- a/level_0/f_file/tests/unit/c/test-file-mode_read.h +++ b/level_0/f_file/tests/unit/c/test-file-mode_read.h @@ -22,9 +22,7 @@ extern void test__f_file_mode_read__fails(void **state); * * @see f_file_mode_read() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_mode_read__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_mode_read__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-mode_read_at.c b/level_0/f_file/tests/unit/c/test-file-mode_read_at.c index f726ec9..0b91df0 100644 --- a/level_0/f_file/tests/unit/c/test-file-mode_read_at.c +++ b/level_0/f_file/tests/unit/c/test-file-mode_read_at.c @@ -48,16 +48,14 @@ void test__f_file_mode_read_at__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_mode_read_at__parameter_checking(void **state) { +void test__f_file_mode_read_at__parameter_checking(void **state) { - { - const f_status_t status = f_file_mode_read_at(0, f_string_empty_s, 0, 0); + { + const f_status_t status = f_file_mode_read_at(0, f_string_empty_s, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_mode_read_at__returns_data_not(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-mode_read_at.h b/level_0/f_file/tests/unit/c/test-file-mode_read_at.h index 647003d..f8c9c1d 100644 --- a/level_0/f_file/tests/unit/c/test-file-mode_read_at.h +++ b/level_0/f_file/tests/unit/c/test-file-mode_read_at.h @@ -22,9 +22,7 @@ extern void test__f_file_mode_read_at__fails(void **state); * * @see f_file_mode_read_at() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_mode_read_at__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_mode_read_at__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-mode_to_mode.c b/level_0/f_file/tests/unit/c/test-file-mode_to_mode.c index 88d5526..2804400 100644 --- a/level_0/f_file/tests/unit/c/test-file-mode_to_mode.c +++ b/level_0/f_file/tests/unit/c/test-file-mode_to_mode.c @@ -5,18 +5,16 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_file_mode_to_mode__parameter_checking(void **state) { +void test__f_file_mode_to_mode__parameter_checking(void **state) { - const f_file_mode_t mode = f_file_mode_t_initialize; + const f_file_mode_t mode = f_file_mode_t_initialize; - { - const f_status_t status = f_file_mode_to_mode(mode, 0); + { + const f_status_t status = f_file_mode_to_mode(mode, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_mode_to_mode__works(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-mode_to_mode.h b/level_0/f_file/tests/unit/c/test-file-mode_to_mode.h index 31ca2e3..025c8cf 100644 --- a/level_0/f_file/tests/unit/c/test-file-mode_to_mode.h +++ b/level_0/f_file/tests/unit/c/test-file-mode_to_mode.h @@ -15,9 +15,7 @@ * * @see f_file_mode_to_mode() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_mode_to_mode__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_mode_to_mode__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_file/tests/unit/c/test-file-name_base.c b/level_0/f_file/tests/unit/c/test-file-name_base.c index a8f0726..024f7d2 100644 --- a/level_0/f_file/tests/unit/c/test-file-name_base.c +++ b/level_0/f_file/tests/unit/c/test-file-name_base.c @@ -5,16 +5,14 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_file_name_base__parameter_checking(void **state) { +void test__f_file_name_base__parameter_checking(void **state) { - { - const f_status_t status = f_file_name_base(f_string_empty_s, 0); + { + const f_status_t status = f_file_name_base(f_string_empty_s, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_name_base__returns_data_not(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-name_base.h b/level_0/f_file/tests/unit/c/test-file-name_base.h index a10492a..5ca3359 100644 --- a/level_0/f_file/tests/unit/c/test-file-name_base.h +++ b/level_0/f_file/tests/unit/c/test-file-name_base.h @@ -15,9 +15,7 @@ * * @see f_file_name_base() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_name_base__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_name_base__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-name_directory.c b/level_0/f_file/tests/unit/c/test-file-name_directory.c index 6fdc8a4..78a7f20 100644 --- a/level_0/f_file/tests/unit/c/test-file-name_directory.c +++ b/level_0/f_file/tests/unit/c/test-file-name_directory.c @@ -5,16 +5,14 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_file_name_directory__parameter_checking(void **state) { +void test__f_file_name_directory__parameter_checking(void **state) { - { - const f_status_t status = f_file_name_directory(f_string_empty_s, 0); + { + const f_status_t status = f_file_name_directory(f_string_empty_s, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_name_directory__returns_data_not(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-name_directory.h b/level_0/f_file/tests/unit/c/test-file-name_directory.h index d540b30..52bd56b 100644 --- a/level_0/f_file/tests/unit/c/test-file-name_directory.h +++ b/level_0/f_file/tests/unit/c/test-file-name_directory.h @@ -15,9 +15,7 @@ * * @see f_file_name_directory() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_name_directory__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_name_directory__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-open.c b/level_0/f_file/tests/unit/c/test-file-open.c index 5cbb4c5..c31d3c9 100644 --- a/level_0/f_file/tests/unit/c/test-file-open.c +++ b/level_0/f_file/tests/unit/c/test-file-open.c @@ -70,18 +70,16 @@ void test__f_file_open__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_open__parameter_checking(void **state) { +void test__f_file_open__parameter_checking(void **state) { - const f_string_static_t path = macro_f_string_static_t_initialize("test", 0, 4); + const f_string_static_t path = macro_f_string_static_t_initialize("test", 0, 4); - { - const f_status_t status = f_file_open(path, 0, 0); + { + const f_status_t status = f_file_open(path, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_open__returns_data_not(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-open.h b/level_0/f_file/tests/unit/c/test-file-open.h index 66fa65a..403abdc 100644 --- a/level_0/f_file/tests/unit/c/test-file-open.h +++ b/level_0/f_file/tests/unit/c/test-file-open.h @@ -22,9 +22,7 @@ extern void test__f_file_open__fails(void **state); * * @see f_file_open() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_open__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_open__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-open_at.c b/level_0/f_file/tests/unit/c/test-file-open_at.c index 6f406ec..7f2df1a 100644 --- a/level_0/f_file/tests/unit/c/test-file-open_at.c +++ b/level_0/f_file/tests/unit/c/test-file-open_at.c @@ -72,16 +72,14 @@ void test__f_file_open_at__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_open_at__parameter_checking(void **state) { +void test__f_file_open_at__parameter_checking(void **state) { - { - const f_status_t status = f_file_open_at(0, f_string_empty_s, 0, 0); + { + const f_status_t status = f_file_open_at(0, f_string_empty_s, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_open_at__returns_data_not(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-open_at.h b/level_0/f_file/tests/unit/c/test-file-open_at.h index 231b8ba..0d75869 100644 --- a/level_0/f_file/tests/unit/c/test-file-open_at.h +++ b/level_0/f_file/tests/unit/c/test-file-open_at.h @@ -22,9 +22,7 @@ extern void test__f_file_open_at__fails(void **state); * * @see f_file_open_at() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_open_at__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_open_at__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-owner_read.c b/level_0/f_file/tests/unit/c/test-file-owner_read.c index ac7e641..a42df6a 100644 --- a/level_0/f_file/tests/unit/c/test-file-owner_read.c +++ b/level_0/f_file/tests/unit/c/test-file-owner_read.c @@ -46,16 +46,14 @@ void test__f_file_owner_read__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_owner_read__parameter_checking(void **state) { +void test__f_file_owner_read__parameter_checking(void **state) { - { - const f_status_t status = f_file_owner_read(f_string_empty_s, F_false, 0); + { + const f_status_t status = f_file_owner_read(f_string_empty_s, F_false, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_owner_read__returns_data_not(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-owner_read.h b/level_0/f_file/tests/unit/c/test-file-owner_read.h index da3a849..6aa68a2 100644 --- a/level_0/f_file/tests/unit/c/test-file-owner_read.h +++ b/level_0/f_file/tests/unit/c/test-file-owner_read.h @@ -22,9 +22,7 @@ extern void test__f_file_owner_read__fails(void **state); * * @see f_file_owner_read() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_owner_read__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_owner_read__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-read.c b/level_0/f_file/tests/unit/c/test-file-read.c index 9223422..2ccfc15 100644 --- a/level_0/f_file/tests/unit/c/test-file-read.c +++ b/level_0/f_file/tests/unit/c/test-file-read.c @@ -49,39 +49,37 @@ void test__f_file_read__fails(void **state) { f_string_dynamic_resize(0, &buffer); } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_read__parameter_checking(void **state) { +void test__f_file_read__parameter_checking(void **state) { - f_file_t file = f_file_t_initialize; - f_string_dynamic_t buffer = f_string_dynamic_t_initialize; - - file.id = 1; + f_file_t file = f_file_t_initialize; + f_string_dynamic_t buffer = f_string_dynamic_t_initialize; - { - const f_status_t status = f_file_read(file, 0); + file.id = 1; - assert_int_equal(status, F_status_set_error(F_parameter)); - } + { + const f_status_t status = f_file_read(file, 0); - file.size_read = 0; + assert_int_equal(status, F_status_set_error(F_parameter)); + } - { - const f_status_t status = f_file_read(file, 0); + file.size_read = 0; - assert_int_equal(status, F_status_set_error(F_parameter)); - } + { + const f_status_t status = f_file_read(file, 0); - { - f_string_dynamic_t string = f_string_dynamic_t_initialize; + assert_int_equal(status, F_status_set_error(F_parameter)); + } - const f_status_t status = f_file_read(file, &string); + { + f_string_dynamic_t string = f_string_dynamic_t_initialize; - assert_int_equal(status, F_status_set_error(F_parameter)); - } + const f_status_t status = f_file_read(file, &string); - f_string_dynamic_resize(0, &buffer); + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ + + f_string_dynamic_resize(0, &buffer); +} void test__f_file_read__returns_file_closed(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-read.h b/level_0/f_file/tests/unit/c/test-file-read.h index e6b89d9..8611710 100644 --- a/level_0/f_file/tests/unit/c/test-file-read.h +++ b/level_0/f_file/tests/unit/c/test-file-read.h @@ -22,9 +22,7 @@ extern void test__f_file_read__fails(void **state); * * @see f_file_read() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_read__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_read__parameter_checking(void **state); /** * Test that function works but the file is closed. diff --git a/level_0/f_file/tests/unit/c/test-file-read_block.c b/level_0/f_file/tests/unit/c/test-file-read_block.c index 8e6b0fa..8b546b6 100644 --- a/level_0/f_file/tests/unit/c/test-file-read_block.c +++ b/level_0/f_file/tests/unit/c/test-file-read_block.c @@ -49,39 +49,37 @@ void test__f_file_read_block__fails(void **state) { f_string_dynamic_resize(0, &buffer); } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_read_block__parameter_checking(void **state) { +void test__f_file_read_block__parameter_checking(void **state) { - f_file_t file = f_file_t_initialize; - f_string_dynamic_t buffer = f_string_dynamic_t_initialize; - - file.id = 1; + f_file_t file = f_file_t_initialize; + f_string_dynamic_t buffer = f_string_dynamic_t_initialize; - { - const f_status_t status = f_file_read_block(file, 0); + file.id = 1; - assert_int_equal(status, F_status_set_error(F_parameter)); - } + { + const f_status_t status = f_file_read_block(file, 0); - file.size_read = 0; + assert_int_equal(status, F_status_set_error(F_parameter)); + } - { - const f_status_t status = f_file_read_block(file, 0); + file.size_read = 0; - assert_int_equal(status, F_status_set_error(F_parameter)); - } + { + const f_status_t status = f_file_read_block(file, 0); - { - f_string_dynamic_t string = f_string_dynamic_t_initialize; + assert_int_equal(status, F_status_set_error(F_parameter)); + } - const f_status_t status = f_file_read_block(file, &string); + { + f_string_dynamic_t string = f_string_dynamic_t_initialize; - assert_int_equal(status, F_status_set_error(F_parameter)); - } + const f_status_t status = f_file_read_block(file, &string); - f_string_dynamic_resize(0, &buffer); + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ + + f_string_dynamic_resize(0, &buffer); +} void test__f_file_read_block__returns_file_closed(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-read_block.h b/level_0/f_file/tests/unit/c/test-file-read_block.h index dfc11e5..d3621b5 100644 --- a/level_0/f_file/tests/unit/c/test-file-read_block.h +++ b/level_0/f_file/tests/unit/c/test-file-read_block.h @@ -22,9 +22,7 @@ extern void test__f_file_read_block__fails(void **state); * * @see f_file_read_block() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_read_block__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_read_block__parameter_checking(void **state); /** * Test that function works but the file is closed. diff --git a/level_0/f_file/tests/unit/c/test-file-read_until.c b/level_0/f_file/tests/unit/c/test-file-read_until.c index 3e44aa6..a3fd48e 100644 --- a/level_0/f_file/tests/unit/c/test-file-read_until.c +++ b/level_0/f_file/tests/unit/c/test-file-read_until.c @@ -49,39 +49,37 @@ void test__f_file_read_until__fails(void **state) { f_string_dynamic_resize(0, &buffer); } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_read_until__parameter_checking(void **state) { +void test__f_file_read_until__parameter_checking(void **state) { - f_file_t file = f_file_t_initialize; - f_string_dynamic_t buffer = f_string_dynamic_t_initialize; - - file.id = 1; + f_file_t file = f_file_t_initialize; + f_string_dynamic_t buffer = f_string_dynamic_t_initialize; - { - const f_status_t status = f_file_read_until(file, 1, 0); + file.id = 1; - assert_int_equal(status, F_status_set_error(F_parameter)); - } + { + const f_status_t status = f_file_read_until(file, 1, 0); - file.size_read = 0; + assert_int_equal(status, F_status_set_error(F_parameter)); + } - { - const f_status_t status = f_file_read_until(file, 1, 0); + file.size_read = 0; - assert_int_equal(status, F_status_set_error(F_parameter)); - } + { + const f_status_t status = f_file_read_until(file, 1, 0); - { - f_string_dynamic_t string = f_string_dynamic_t_initialize; + assert_int_equal(status, F_status_set_error(F_parameter)); + } - const f_status_t status = f_file_read_until(file, 1, &string); + { + f_string_dynamic_t string = f_string_dynamic_t_initialize; - assert_int_equal(status, F_status_set_error(F_parameter)); - } + const f_status_t status = f_file_read_until(file, 1, &string); - f_string_dynamic_resize(0, &buffer); + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ + + f_string_dynamic_resize(0, &buffer); +} void test__f_file_read_until__returns_file_closed(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-read_until.h b/level_0/f_file/tests/unit/c/test-file-read_until.h index 88de066..c6f1513 100644 --- a/level_0/f_file/tests/unit/c/test-file-read_until.h +++ b/level_0/f_file/tests/unit/c/test-file-read_until.h @@ -22,9 +22,7 @@ extern void test__f_file_read_until__fails(void **state); * * @see f_file_read_until() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_read_until__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_read_until__parameter_checking(void **state); /** * Test that function works but the file is closed. diff --git a/level_0/f_file/tests/unit/c/test-file-seek.c b/level_0/f_file/tests/unit/c/test-file-seek.c index 8f03596..5ce244a 100644 --- a/level_0/f_file/tests/unit/c/test-file-seek.c +++ b/level_0/f_file/tests/unit/c/test-file-seek.c @@ -38,30 +38,28 @@ void test__f_file_seek__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_seek__parameter_checking(void **state) { +void test__f_file_seek__parameter_checking(void **state) { - off_t seeked = 0; + off_t seeked = 0; - { - const f_status_t status = f_file_seek(0, -1, 0, 0); + { + const f_status_t status = f_file_seek(0, -1, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); + } - { - const f_status_t status = f_file_seek(0, -1, 0, &seeked); + { + const f_status_t status = f_file_seek(0, -1, 0, &seeked); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); + } - { - const f_status_t status = f_file_seek(0, 0, 0, 0); + { + const f_status_t status = f_file_seek(0, 0, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_seek__works(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-seek.h b/level_0/f_file/tests/unit/c/test-file-seek.h index 32938d5..776ea21 100644 --- a/level_0/f_file/tests/unit/c/test-file-seek.h +++ b/level_0/f_file/tests/unit/c/test-file-seek.h @@ -22,9 +22,7 @@ extern void test__f_file_seek__fails(void **state); * * @see f_file_seek() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_seek__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_seek__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_file/tests/unit/c/test-file-size.c b/level_0/f_file/tests/unit/c/test-file-size.c index ee07e1e..1dfcf90 100644 --- a/level_0/f_file/tests/unit/c/test-file-size.c +++ b/level_0/f_file/tests/unit/c/test-file-size.c @@ -48,16 +48,14 @@ void test__f_file_size__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_size__parameter_checking(void **state) { +void test__f_file_size__parameter_checking(void **state) { - { - const f_status_t status = f_file_size(f_string_empty_s, F_false, 0); + { + const f_status_t status = f_file_size(f_string_empty_s, F_false, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_size__returns_data_not(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-size.h b/level_0/f_file/tests/unit/c/test-file-size.h index a753a4f..d92c91c 100644 --- a/level_0/f_file/tests/unit/c/test-file-size.h +++ b/level_0/f_file/tests/unit/c/test-file-size.h @@ -22,9 +22,7 @@ extern void test__f_file_size__fails(void **state); * * @see f_file_size() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_size__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_size__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-size_at.c b/level_0/f_file/tests/unit/c/test-file-size_at.c index b5559de..c402e4c 100644 --- a/level_0/f_file/tests/unit/c/test-file-size_at.c +++ b/level_0/f_file/tests/unit/c/test-file-size_at.c @@ -50,16 +50,14 @@ void test__f_file_size_at__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_size_at__parameter_checking(void **state) { +void test__f_file_size_at__parameter_checking(void **state) { - { - const f_status_t status = f_file_size_at(0, f_string_empty_s, F_false, 0); + { + const f_status_t status = f_file_size_at(0, f_string_empty_s, F_false, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_size_at__returns_data_not(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-size_at.h b/level_0/f_file/tests/unit/c/test-file-size_at.h index 83b5314..dcc977c 100644 --- a/level_0/f_file/tests/unit/c/test-file-size_at.h +++ b/level_0/f_file/tests/unit/c/test-file-size_at.h @@ -22,9 +22,7 @@ extern void test__f_file_size_at__fails(void **state); * * @see f_file_size_at() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_size_at__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_size_at__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-size_by_id.c b/level_0/f_file/tests/unit/c/test-file-size_by_id.c index 8bf580f..ceb8f20 100644 --- a/level_0/f_file/tests/unit/c/test-file-size_by_id.c +++ b/level_0/f_file/tests/unit/c/test-file-size_by_id.c @@ -48,16 +48,14 @@ void test__f_file_size_by_id__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_size_by_id__parameter_checking(void **state) { +void test__f_file_size_by_id__parameter_checking(void **state) { - { - const f_status_t status = f_file_size_by_id(0, 0); + { + const f_status_t status = f_file_size_by_id(0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_size_by_id__returns_file_closed(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-size_by_id.h b/level_0/f_file/tests/unit/c/test-file-size_by_id.h index 088faa6..095e598 100644 --- a/level_0/f_file/tests/unit/c/test-file-size_by_id.h +++ b/level_0/f_file/tests/unit/c/test-file-size_by_id.h @@ -22,9 +22,7 @@ extern void test__f_file_size_by_id__fails(void **state); * * @see f_file_size_by_id() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_size_by_id__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_size_by_id__parameter_checking(void **state); /** * Test that function works but the file is closed. diff --git a/level_0/f_file/tests/unit/c/test-file-stat.c b/level_0/f_file/tests/unit/c/test-file-stat.c index 29dca5c..264985d 100644 --- a/level_0/f_file/tests/unit/c/test-file-stat.c +++ b/level_0/f_file/tests/unit/c/test-file-stat.c @@ -50,16 +50,14 @@ void test__f_file_stat__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_stat__parameter_checking(void **state) { +void test__f_file_stat__parameter_checking(void **state) { - { - const f_status_t status = f_file_stat(f_string_empty_s, F_false, 0); + { + const f_status_t status = f_file_stat(f_string_empty_s, F_false, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_stat__returns_data_not(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-stat.h b/level_0/f_file/tests/unit/c/test-file-stat.h index ddb361c..edc7780 100644 --- a/level_0/f_file/tests/unit/c/test-file-stat.h +++ b/level_0/f_file/tests/unit/c/test-file-stat.h @@ -22,9 +22,7 @@ extern void test__f_file_stat__fails(void **state); * * @see f_file_stat() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_stat__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_stat__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-stat_at.c b/level_0/f_file/tests/unit/c/test-file-stat_at.c index 4d9aee0..284ff71 100644 --- a/level_0/f_file/tests/unit/c/test-file-stat_at.c +++ b/level_0/f_file/tests/unit/c/test-file-stat_at.c @@ -52,16 +52,14 @@ void test__f_file_stat_at__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_stat_at__parameter_checking(void **state) { +void test__f_file_stat_at__parameter_checking(void **state) { - { - const f_status_t status = f_file_stat_at(0, f_string_empty_s, F_false, 0); + { + const f_status_t status = f_file_stat_at(0, f_string_empty_s, F_false, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_stat_at__returns_data_not(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-stat_at.h b/level_0/f_file/tests/unit/c/test-file-stat_at.h index 733aebe..5382460 100644 --- a/level_0/f_file/tests/unit/c/test-file-stat_at.h +++ b/level_0/f_file/tests/unit/c/test-file-stat_at.h @@ -22,9 +22,7 @@ extern void test__f_file_stat_at__fails(void **state); * * @see f_file_stat_at() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_stat_at__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_stat_at__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-stat_by_id.c b/level_0/f_file/tests/unit/c/test-file-stat_by_id.c index ba220ef..7282fa0 100644 --- a/level_0/f_file/tests/unit/c/test-file-stat_by_id.c +++ b/level_0/f_file/tests/unit/c/test-file-stat_by_id.c @@ -50,16 +50,14 @@ void test__f_file_stat_by_id__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_stat_by_id__parameter_checking(void **state) { +void test__f_file_stat_by_id__parameter_checking(void **state) { - { - const f_status_t status = f_file_stat_by_id(0, 0); + { + const f_status_t status = f_file_stat_by_id(0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_stat_by_id__returns_file_closed(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-stat_by_id.h b/level_0/f_file/tests/unit/c/test-file-stat_by_id.h index 2565d26..bb47bea 100644 --- a/level_0/f_file/tests/unit/c/test-file-stat_by_id.h +++ b/level_0/f_file/tests/unit/c/test-file-stat_by_id.h @@ -22,9 +22,7 @@ extern void test__f_file_stat_by_id__fails(void **state); * * @see f_file_stat_by_id() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_stat_by_id__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_stat_by_id__parameter_checking(void **state); /** * Test that function works but the file is closed. diff --git a/level_0/f_file/tests/unit/c/test-file-stream_close.c b/level_0/f_file/tests/unit/c/test-file-stream_close.c index 3c42a81..26404fc 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_close.c +++ b/level_0/f_file/tests/unit/c/test-file-stream_close.c @@ -151,16 +151,14 @@ void test__f_file_stream_close__fails_for_stream(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_stream_close__parameter_checking(void **state) { +void test__f_file_stream_close__parameter_checking(void **state) { - { - const f_status_t status = f_file_stream_close(F_false, 0); + { + const f_status_t status = f_file_stream_close(F_false, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_stream_close__works(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-stream_close.h b/level_0/f_file/tests/unit/c/test-file-stream_close.h index 5eeffc0..978dff7 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_close.h +++ b/level_0/f_file/tests/unit/c/test-file-stream_close.h @@ -29,9 +29,7 @@ extern void test__f_file_stream_close__fails_for_stream(void **state); * * @see f_file_stream_close() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_stream_close__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_stream_close__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_file/tests/unit/c/test-file-stream_open.c b/level_0/f_file/tests/unit/c/test-file-stream_open.c index 38726c8..aa3aa29 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_open.c +++ b/level_0/f_file/tests/unit/c/test-file-stream_open.c @@ -82,16 +82,14 @@ void test__f_file_stream_open__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_stream_open__parameter_checking(void **state) { +void test__f_file_stream_open__parameter_checking(void **state) { - { - const f_status_t status = f_file_stream_open(f_string_empty_s, f_string_empty_s, 0); + { + const f_status_t status = f_file_stream_open(f_string_empty_s, f_string_empty_s, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_stream_open__returns_data_not(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-stream_open.h b/level_0/f_file/tests/unit/c/test-file-stream_open.h index 21772b4..657cc93 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_open.h +++ b/level_0/f_file/tests/unit/c/test-file-stream_open.h @@ -22,9 +22,7 @@ extern void test__f_file_stream_open__fails(void **state); * * @see f_file_stream_open() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_stream_open__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_stream_open__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-stream_open_descriptor.c b/level_0/f_file/tests/unit/c/test-file-stream_open_descriptor.c index 317ac8e..db29ca5 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_open_descriptor.c +++ b/level_0/f_file/tests/unit/c/test-file-stream_open_descriptor.c @@ -80,16 +80,14 @@ void test__f_file_stream_open_descriptor__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_stream_open_descriptor__parameter_checking(void **state) { +void test__f_file_stream_open_descriptor__parameter_checking(void **state) { - { - const f_status_t status = f_file_stream_open_descriptor(f_string_empty_s, 0); + { + const f_status_t status = f_file_stream_open_descriptor(f_string_empty_s, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_stream_open_descriptor__works(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-stream_open_descriptor.h b/level_0/f_file/tests/unit/c/test-file-stream_open_descriptor.h index a2deb6d..677d729 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_open_descriptor.h +++ b/level_0/f_file/tests/unit/c/test-file-stream_open_descriptor.h @@ -22,9 +22,7 @@ extern void test__f_file_stream_open_descriptor__fails(void **state); * * @see f_file_stream_open_descriptor() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_stream_open_descriptor__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_stream_open_descriptor__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_file/tests/unit/c/test-file-stream_read.c b/level_0/f_file/tests/unit/c/test-file-stream_read.c index fcdf1a7..95ca854 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_read.c +++ b/level_0/f_file/tests/unit/c/test-file-stream_read.c @@ -59,34 +59,32 @@ void test__f_file_stream_read__fails(void **state) { f_string_dynamic_resize(0, &buffer); } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_stream_read__parameter_checking(void **state) { +void test__f_file_stream_read__parameter_checking(void **state) { - f_file_t file = f_file_t_initialize; + f_file_t file = f_file_t_initialize; - { - const f_status_t status = f_file_stream_read(file, 0); + { + const f_status_t status = f_file_stream_read(file, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); + } - file.size_read = 0; + file.size_read = 0; - { - const f_status_t status = f_file_stream_read(file, 0); + { + const f_status_t status = f_file_stream_read(file, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); + } - { - f_string_dynamic_t string = f_string_dynamic_t_initialize; + { + f_string_dynamic_t string = f_string_dynamic_t_initialize; - const f_status_t status = f_file_stream_read(file, &string); + const f_status_t status = f_file_stream_read(file, &string); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_stream_read__returns_file_closed(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-stream_read.h b/level_0/f_file/tests/unit/c/test-file-stream_read.h index 5c88393..72b98b1 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_read.h +++ b/level_0/f_file/tests/unit/c/test-file-stream_read.h @@ -22,9 +22,7 @@ extern void test__f_file_stream_read__fails(void **state); * * @see f_file_stream_read() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_stream_read__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_stream_read__parameter_checking(void **state); /** * Test that function works but the file stream is closed. diff --git a/level_0/f_file/tests/unit/c/test-file-stream_read_block.c b/level_0/f_file/tests/unit/c/test-file-stream_read_block.c index 2f0f122..fec3f97 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_read_block.c +++ b/level_0/f_file/tests/unit/c/test-file-stream_read_block.c @@ -59,34 +59,32 @@ void test__f_file_stream_read_block__fails(void **state) { f_string_dynamic_resize(0, &buffer); } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_stream_read_block__parameter_checking(void **state) { +void test__f_file_stream_read_block__parameter_checking(void **state) { - f_file_t file = f_file_t_initialize; + f_file_t file = f_file_t_initialize; - { - const f_status_t status = f_file_stream_read_block(file, 0); + { + const f_status_t status = f_file_stream_read_block(file, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); + } - file.size_read = 0; + file.size_read = 0; - { - const f_status_t status = f_file_stream_read_block(file, 0); + { + const f_status_t status = f_file_stream_read_block(file, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); + } - { - f_string_dynamic_t string = f_string_dynamic_t_initialize; + { + f_string_dynamic_t string = f_string_dynamic_t_initialize; - const f_status_t status = f_file_stream_read_block(file, &string); + const f_status_t status = f_file_stream_read_block(file, &string); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_stream_read_block__returns_file_closed(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-stream_read_block.h b/level_0/f_file/tests/unit/c/test-file-stream_read_block.h index aeea39f..7e8960d 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_read_block.h +++ b/level_0/f_file/tests/unit/c/test-file-stream_read_block.h @@ -22,9 +22,7 @@ extern void test__f_file_stream_read_block__fails(void **state); * * @see f_file_stream_read_block() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_stream_read_block__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_stream_read_block__parameter_checking(void **state); /** * Test that function works but the file stream is closed. diff --git a/level_0/f_file/tests/unit/c/test-file-stream_read_until.c b/level_0/f_file/tests/unit/c/test-file-stream_read_until.c index c8a408c..c7578b4 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_read_until.c +++ b/level_0/f_file/tests/unit/c/test-file-stream_read_until.c @@ -59,34 +59,32 @@ void test__f_file_stream_read_until__fails(void **state) { f_string_dynamic_resize(0, &buffer); } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_stream_read_until__parameter_checking(void **state) { +void test__f_file_stream_read_until__parameter_checking(void **state) { f_file_t file = f_file_t_initialize; - { - const f_status_t status = f_file_stream_read_until(file, 0, 0); + { + const f_status_t status = f_file_stream_read_until(file, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); + } - file.size_read = 0; + file.size_read = 0; - { - const f_status_t status = f_file_stream_read_until(file, 0, 0); + { + const f_status_t status = f_file_stream_read_until(file, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); + } - { - f_string_dynamic_t string = f_string_dynamic_t_initialize; + { + f_string_dynamic_t string = f_string_dynamic_t_initialize; - const f_status_t status = f_file_stream_read_until(file, 0, &string); + const f_status_t status = f_file_stream_read_until(file, 0, &string); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_stream_read_until__returns_file_closed(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-stream_read_until.h b/level_0/f_file/tests/unit/c/test-file-stream_read_until.h index c7d811f..4bc01ea 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_read_until.h +++ b/level_0/f_file/tests/unit/c/test-file-stream_read_until.h @@ -22,9 +22,7 @@ extern void test__f_file_stream_read_until__fails(void **state); * * @see f_file_stream_read_until() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_stream_read_until__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_stream_read_until__parameter_checking(void **state); /** * Test that function works but the file stream is closed. diff --git a/level_0/f_file/tests/unit/c/test-file-stream_reopen.c b/level_0/f_file/tests/unit/c/test-file-stream_reopen.c index a208463..e0645fc 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_reopen.c +++ b/level_0/f_file/tests/unit/c/test-file-stream_reopen.c @@ -78,16 +78,14 @@ void test__f_file_stream_reopen__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_stream_reopen__parameter_checking(void **state) { +void test__f_file_stream_reopen__parameter_checking(void **state) { - { - const f_status_t status = f_file_stream_reopen(f_string_empty_s, f_string_empty_s, 0); + { + const f_status_t status = f_file_stream_reopen(f_string_empty_s, f_string_empty_s, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_stream_reopen__returns_data_not(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-stream_reopen.h b/level_0/f_file/tests/unit/c/test-file-stream_reopen.h index abd5768..3422ad8 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_reopen.h +++ b/level_0/f_file/tests/unit/c/test-file-stream_reopen.h @@ -22,9 +22,7 @@ extern void test__f_file_stream_reopen__fails(void **state); * * @see f_file_stream_reopen() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_stream_reopen__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_stream_reopen__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-stream_write.c b/level_0/f_file/tests/unit/c/test-file-stream_write.c index 7af121d..683e1ec 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_write.c +++ b/level_0/f_file/tests/unit/c/test-file-stream_write.c @@ -51,19 +51,17 @@ void test__f_file_stream_write__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_stream_write__parameter_checking(void **state) { +void test__f_file_stream_write__parameter_checking(void **state) { - f_file_t file = f_file_t_initialize; - file.size_write = 0; + f_file_t file = f_file_t_initialize; + file.size_write = 0; - { - const f_status_t status = f_file_stream_write(file, f_string_empty_s, 0); + { + const f_status_t status = f_file_stream_write(file, f_string_empty_s, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_stream_write__returns_file_closed(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-stream_write.h b/level_0/f_file/tests/unit/c/test-file-stream_write.h index d28a941..839b259 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_write.h +++ b/level_0/f_file/tests/unit/c/test-file-stream_write.h @@ -22,9 +22,7 @@ extern void test__f_file_stream_write__fails(void **state); * * @see f_file_stream_write() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_stream_write__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_stream_write__parameter_checking(void **state); /** * Test that function works but the file stream is closed. diff --git a/level_0/f_file/tests/unit/c/test-file-stream_write_block.c b/level_0/f_file/tests/unit/c/test-file-stream_write_block.c index 40e9d1a..3716b35 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_write_block.c +++ b/level_0/f_file/tests/unit/c/test-file-stream_write_block.c @@ -51,19 +51,17 @@ void test__f_file_stream_write_block__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_stream_write_block__parameter_checking(void **state) { +void test__f_file_stream_write_block__parameter_checking(void **state) { - f_file_t file = f_file_t_initialize; - file.size_write = 0; + f_file_t file = f_file_t_initialize; + file.size_write = 0; - { - const f_status_t status = f_file_stream_write_block(file, f_string_empty_s, 0); + { + const f_status_t status = f_file_stream_write_block(file, f_string_empty_s, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_stream_write_block__returns_file_closed(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-stream_write_block.h b/level_0/f_file/tests/unit/c/test-file-stream_write_block.h index 0125d97..61e9671 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_write_block.h +++ b/level_0/f_file/tests/unit/c/test-file-stream_write_block.h @@ -22,9 +22,7 @@ extern void test__f_file_stream_write_block__fails(void **state); * * @see f_file_stream_write_block() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_stream_write_block__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_stream_write_block__parameter_checking(void **state); /** * Test that function works but the file stream is closed. diff --git a/level_0/f_file/tests/unit/c/test-file-stream_write_range.c b/level_0/f_file/tests/unit/c/test-file-stream_write_range.c index 34cbb22..c00e90d 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_write_range.c +++ b/level_0/f_file/tests/unit/c/test-file-stream_write_range.c @@ -52,21 +52,19 @@ void test__f_file_stream_write_range__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_stream_write_range__parameter_checking(void **state) { +void test__f_file_stream_write_range__parameter_checking(void **state) { - f_file_t file = f_file_t_initialize; - file.size_write = 0; + f_file_t file = f_file_t_initialize; + file.size_write = 0; - const f_string_range_t range = f_string_range_t_initialize; + const f_string_range_t range = f_string_range_t_initialize; - { - const f_status_t status = f_file_stream_write_range(file, f_string_empty_s, range, 0); + { + const f_status_t status = f_file_stream_write_range(file, f_string_empty_s, range, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_stream_write_range__returns_file_closed(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-stream_write_range.h b/level_0/f_file/tests/unit/c/test-file-stream_write_range.h index ac9d392..49eadff 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_write_range.h +++ b/level_0/f_file/tests/unit/c/test-file-stream_write_range.h @@ -22,9 +22,7 @@ extern void test__f_file_stream_write_range__fails(void **state); * * @see f_file_stream_write_range() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_stream_write_range__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_stream_write_range__parameter_checking(void **state); /** * Test that function works but the file stream is closed. diff --git a/level_0/f_file/tests/unit/c/test-file-stream_write_until.c b/level_0/f_file/tests/unit/c/test-file-stream_write_until.c index fba5f52..fb882b9 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_write_until.c +++ b/level_0/f_file/tests/unit/c/test-file-stream_write_until.c @@ -51,19 +51,17 @@ void test__f_file_stream_write_until__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_stream_write_until__parameter_checking(void **state) { +void test__f_file_stream_write_until__parameter_checking(void **state) { - f_file_t file = f_file_t_initialize; - file.size_write = 0; + f_file_t file = f_file_t_initialize; + file.size_write = 0; - { - const f_status_t status = f_file_stream_write_until(file, f_string_empty_s, 0, 0); + { + const f_status_t status = f_file_stream_write_until(file, f_string_empty_s, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_stream_write_until__returns_file_closed(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-stream_write_until.h b/level_0/f_file/tests/unit/c/test-file-stream_write_until.h index 48b9092..dc30e05 100644 --- a/level_0/f_file/tests/unit/c/test-file-stream_write_until.h +++ b/level_0/f_file/tests/unit/c/test-file-stream_write_until.h @@ -22,9 +22,7 @@ extern void test__f_file_stream_write_until__fails(void **state); * * @see f_file_stream_write_until() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_stream_write_until__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_stream_write_until__parameter_checking(void **state); /** * Test that function works but the file stream is closed. diff --git a/level_0/f_file/tests/unit/c/test-file-type.c b/level_0/f_file/tests/unit/c/test-file-type.c index a35807e..8f415ea 100644 --- a/level_0/f_file/tests/unit/c/test-file-type.c +++ b/level_0/f_file/tests/unit/c/test-file-type.c @@ -48,16 +48,14 @@ void test__f_file_type__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_type__parameter_checking(void **state) { +void test__f_file_type__parameter_checking(void **state) { - { - const f_status_t status = f_file_type(f_string_empty_s, F_true, 0); + { + const f_status_t status = f_file_type(f_string_empty_s, F_true, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_type__returns_data_not(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-type.h b/level_0/f_file/tests/unit/c/test-file-type.h index da8004d..7b79d08 100644 --- a/level_0/f_file/tests/unit/c/test-file-type.h +++ b/level_0/f_file/tests/unit/c/test-file-type.h @@ -22,9 +22,7 @@ extern void test__f_file_type__fails(void **state); * * @see f_file_type() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_type__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_type__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-type_at.c b/level_0/f_file/tests/unit/c/test-file-type_at.c index 229f63a..92d11a0 100644 --- a/level_0/f_file/tests/unit/c/test-file-type_at.c +++ b/level_0/f_file/tests/unit/c/test-file-type_at.c @@ -48,16 +48,14 @@ void test__f_file_type_at__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_type_at__parameter_checking(void **state) { +void test__f_file_type_at__parameter_checking(void **state) { - { - const f_status_t status = f_file_type_at(0, f_string_empty_s, 0, 0); + { + const f_status_t status = f_file_type_at(0, f_string_empty_s, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_type_at__returns_data_not(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-type_at.h b/level_0/f_file/tests/unit/c/test-file-type_at.h index 69b0dc5..ea11010 100644 --- a/level_0/f_file/tests/unit/c/test-file-type_at.h +++ b/level_0/f_file/tests/unit/c/test-file-type_at.h @@ -22,9 +22,7 @@ extern void test__f_file_type_at__fails(void **state); * * @see f_file_type_at() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_type_at__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_type_at__parameter_checking(void **state); /** * Test that function works but the path is empty. diff --git a/level_0/f_file/tests/unit/c/test-file-umask_get.c b/level_0/f_file/tests/unit/c/test-file-umask_get.c index d9cd6e1..77da3e8 100644 --- a/level_0/f_file/tests/unit/c/test-file-umask_get.c +++ b/level_0/f_file/tests/unit/c/test-file-umask_get.c @@ -5,16 +5,14 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_file_umask_get__parameter_checking(void **state) { +void test__f_file_umask_get__parameter_checking(void **state) { - { - const f_status_t status = f_file_umask_get(0); + { + const f_status_t status = f_file_umask_get(0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_umask_get__works(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-umask_get.h b/level_0/f_file/tests/unit/c/test-file-umask_get.h index b3574e8..2dab7ea 100644 --- a/level_0/f_file/tests/unit/c/test-file-umask_get.h +++ b/level_0/f_file/tests/unit/c/test-file-umask_get.h @@ -15,9 +15,7 @@ * * @see f_file_umask_get() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_umask_get__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_umask_get__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_file/tests/unit/c/test-file-write.c b/level_0/f_file/tests/unit/c/test-file-write.c index 301bf70..3393cbc 100644 --- a/level_0/f_file/tests/unit/c/test-file-write.c +++ b/level_0/f_file/tests/unit/c/test-file-write.c @@ -65,19 +65,17 @@ void test__f_file_write__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_write__parameter_checking(void **state) { +void test__f_file_write__parameter_checking(void **state) { - f_file_t file = f_file_t_initialize; - file.size_write = 0; + f_file_t file = f_file_t_initialize; + file.size_write = 0; - { - const f_status_t status = f_file_write(file, f_string_empty_s, 0); + { + const f_status_t status = f_file_write(file, f_string_empty_s, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_write__returns_file_closed(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-write.h b/level_0/f_file/tests/unit/c/test-file-write.h index 39f3fd9..797291e 100644 --- a/level_0/f_file/tests/unit/c/test-file-write.h +++ b/level_0/f_file/tests/unit/c/test-file-write.h @@ -22,9 +22,7 @@ extern void test__f_file_write__fails(void **state); * * @see f_file_write() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_write__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_write__parameter_checking(void **state); /** * Test that function works but the file is closed. diff --git a/level_0/f_file/tests/unit/c/test-file-write_block.c b/level_0/f_file/tests/unit/c/test-file-write_block.c index 406923d..1db4be2 100644 --- a/level_0/f_file/tests/unit/c/test-file-write_block.c +++ b/level_0/f_file/tests/unit/c/test-file-write_block.c @@ -48,19 +48,17 @@ void test__f_file_write_block__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_write_block__parameter_checking(void **state) { +void test__f_file_write_block__parameter_checking(void **state) { - f_file_t file = f_file_t_initialize; - file.size_write = 0; + f_file_t file = f_file_t_initialize; + file.size_write = 0; - { - const f_status_t status = f_file_write_block(file, f_string_empty_s, 0); + { + const f_status_t status = f_file_write_block(file, f_string_empty_s, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_write_block__returns_file_closed(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-write_block.h b/level_0/f_file/tests/unit/c/test-file-write_block.h index efebb31..8dd23af 100644 --- a/level_0/f_file/tests/unit/c/test-file-write_block.h +++ b/level_0/f_file/tests/unit/c/test-file-write_block.h @@ -22,9 +22,7 @@ extern void test__f_file_write_block__fails(void **state); * * @see f_file_write_block() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_write_block__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_write_block__parameter_checking(void **state); /** * Test that function works but the file is closed. diff --git a/level_0/f_file/tests/unit/c/test-file-write_range.c b/level_0/f_file/tests/unit/c/test-file-write_range.c index 3cb1f65..be95933 100644 --- a/level_0/f_file/tests/unit/c/test-file-write_range.c +++ b/level_0/f_file/tests/unit/c/test-file-write_range.c @@ -49,21 +49,19 @@ void test__f_file_write_range__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_write_range__parameter_checking(void **state) { +void test__f_file_write_range__parameter_checking(void **state) { - f_file_t file = f_file_t_initialize; - file.size_write = 0; + f_file_t file = f_file_t_initialize; + file.size_write = 0; - const f_string_range_t range = f_string_range_t_initialize; + const f_string_range_t range = f_string_range_t_initialize; - { - const f_status_t status = f_file_write_range(file, f_string_empty_s, range, 0); + { + const f_status_t status = f_file_write_range(file, f_string_empty_s, range, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_write_range__returns_file_closed(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-write_range.h b/level_0/f_file/tests/unit/c/test-file-write_range.h index ee6b223..cbc1c60 100644 --- a/level_0/f_file/tests/unit/c/test-file-write_range.h +++ b/level_0/f_file/tests/unit/c/test-file-write_range.h @@ -22,9 +22,7 @@ extern void test__f_file_write_range__fails(void **state); * * @see f_file_write_range() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_write_range__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_write_range__parameter_checking(void **state); /** * Test that function works but the file is closed. diff --git a/level_0/f_file/tests/unit/c/test-file-write_until.c b/level_0/f_file/tests/unit/c/test-file-write_until.c index aa71a6d..771b7c2 100644 --- a/level_0/f_file/tests/unit/c/test-file-write_until.c +++ b/level_0/f_file/tests/unit/c/test-file-write_until.c @@ -48,19 +48,17 @@ void test__f_file_write_until__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_file_write_until__parameter_checking(void **state) { +void test__f_file_write_until__parameter_checking(void **state) { - f_file_t file = f_file_t_initialize; - file.size_write = 0; + f_file_t file = f_file_t_initialize; + file.size_write = 0; - { - const f_status_t status = f_file_write_until(file, f_string_empty_s, 0, 0); + { + const f_status_t status = f_file_write_until(file, f_string_empty_s, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_file_write_until__returns_file_closed(void **state) { diff --git a/level_0/f_file/tests/unit/c/test-file-write_until.h b/level_0/f_file/tests/unit/c/test-file-write_until.h index 03e9df7..ecfec26 100644 --- a/level_0/f_file/tests/unit/c/test-file-write_until.h +++ b/level_0/f_file/tests/unit/c/test-file-write_until.h @@ -22,9 +22,7 @@ extern void test__f_file_write_until__fails(void **state); * * @see f_file_write_until() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_file_write_until__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_file_write_until__parameter_checking(void **state); /** * Test that function works but the file is closed. diff --git a/level_0/f_iki/tests/unit/c/test-iki-content_is.c b/level_0/f_iki/tests/unit/c/test-iki-content_is.c index f66e749..5675ffc 100644 --- a/level_0/f_iki/tests/unit/c/test-iki-content_is.c +++ b/level_0/f_iki/tests/unit/c/test-iki-content_is.c @@ -41,16 +41,14 @@ void test__f_iki_content_is__returns_false(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_iki_content_is__parameter_checking(void **state) { +void test__f_iki_content_is__parameter_checking(void **state) { - { - const f_status_t status = f_iki_content_is(f_string_empty_s, f_string_empty_s); + { + const f_status_t status = f_iki_content_is(f_string_empty_s, f_string_empty_s); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_iki_content_is__returns_data_not(void **state) { diff --git a/level_0/f_iki/tests/unit/c/test-iki-content_is.h b/level_0/f_iki/tests/unit/c/test-iki-content_is.h index c876cb6..d33f1db 100644 --- a/level_0/f_iki/tests/unit/c/test-iki-content_is.h +++ b/level_0/f_iki/tests/unit/c/test-iki-content_is.h @@ -22,9 +22,7 @@ extern void test__f_iki_content_is__returns_false(void **state); * * @see f_iki_content_is() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_iki_content_is__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_iki_content_is__parameter_checking(void **state); /** * Test that function returns F_data_not. diff --git a/level_0/f_iki/tests/unit/c/test-iki-content_partial_is.c b/level_0/f_iki/tests/unit/c/test-iki-content_partial_is.c index c039071..a31c062 100644 --- a/level_0/f_iki/tests/unit/c/test-iki-content_partial_is.c +++ b/level_0/f_iki/tests/unit/c/test-iki-content_partial_is.c @@ -57,18 +57,16 @@ void test__f_iki_content_partial_is__returns_false(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_iki_content_partial_is__parameter_checking(void **state) { +void test__f_iki_content_partial_is__parameter_checking(void **state) { - { - const f_string_range_t range = f_string_range_t_initialize; + { + const f_string_range_t range = f_string_range_t_initialize; - const f_status_t status = f_iki_content_partial_is(f_string_empty_s, range, f_string_empty_s); + const f_status_t status = f_iki_content_partial_is(f_string_empty_s, range, f_string_empty_s); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_iki_content_partial_is__returns_data_not(void **state) { diff --git a/level_0/f_iki/tests/unit/c/test-iki-content_partial_is.h b/level_0/f_iki/tests/unit/c/test-iki-content_partial_is.h index b411147..01b05b9 100644 --- a/level_0/f_iki/tests/unit/c/test-iki-content_partial_is.h +++ b/level_0/f_iki/tests/unit/c/test-iki-content_partial_is.h @@ -22,9 +22,7 @@ extern void test__f_iki_content_partial_is__returns_false(void **state); * * @see f_iki_content_partial_is() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_iki_content_partial_is__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_iki_content_partial_is__parameter_checking(void **state); /** * Test that function returns F_data_not. diff --git a/level_0/f_iki/tests/unit/c/test-iki-read.c b/level_0/f_iki/tests/unit/c/test-iki-read.c index 1f6a02d..7092e71 100644 --- a/level_0/f_iki/tests/unit/c/test-iki-read.c +++ b/level_0/f_iki/tests/unit/c/test-iki-read.c @@ -5,38 +5,36 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_iki_read__parameter_checking(void **state) { +void test__f_iki_read__parameter_checking(void **state) { - const f_state_t the_state = f_state_t_initialize; - f_string_static_t empty = macro_f_string_static_t_initialize(f_string_empty_s.string, f_string_empty_s.size, f_string_empty_s.used); + const f_state_t the_state = f_state_t_initialize; + f_string_static_t empty = macro_f_string_static_t_initialize(f_string_empty_s.string, f_string_empty_s.size, f_string_empty_s.used); - { - f_string_range_t range = f_string_range_t_initialize; - f_iki_data_t iki = f_iki_data_t_initialize; + { + f_string_range_t range = f_string_range_t_initialize; + f_iki_data_t iki = f_iki_data_t_initialize; - const f_status_t status = f_iki_read(the_state, 0, &range, &iki); + const f_status_t status = f_iki_read(the_state, 0, &range, &iki); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); + } - { - f_iki_data_t iki = f_iki_data_t_initialize; + { + f_iki_data_t iki = f_iki_data_t_initialize; - const f_status_t status = f_iki_read(the_state, &empty, 0, &iki); + const f_status_t status = f_iki_read(the_state, &empty, 0, &iki); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); + } - { - f_string_range_t range = f_string_range_t_initialize; + { + f_string_range_t range = f_string_range_t_initialize; - const f_status_t status = f_iki_read(the_state, &empty, &range, 0); + const f_status_t status = f_iki_read(the_state, &empty, &range, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_iki_read__returns_data_not(void **state) { diff --git a/level_0/f_iki/tests/unit/c/test-iki-read.h b/level_0/f_iki/tests/unit/c/test-iki-read.h index 16dba9f..282c1c3 100644 --- a/level_0/f_iki/tests/unit/c/test-iki-read.h +++ b/level_0/f_iki/tests/unit/c/test-iki-read.h @@ -15,9 +15,7 @@ * * @see f_iki_read() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_iki_read__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_iki_read__parameter_checking(void **state); /** * Test that function returns F_data_not. diff --git a/level_0/f_limit/tests/unit/c/test-limit-process.c b/level_0/f_limit/tests/unit/c/test-limit-process.c index a073c62..53bff77 100644 --- a/level_0/f_limit/tests/unit/c/test-limit-process.c +++ b/level_0/f_limit/tests/unit/c/test-limit-process.c @@ -36,16 +36,14 @@ void test__f_limit_process__fails(void **state) { } // for } -#ifndef _di_level_0_parameter_checking_ - void test__f_limit_process__parameter_checking(void **state) { +void test__f_limit_process__parameter_checking(void **state) { - { - const f_status_t status = f_limit_process(1, 1, 0, 0); + { + const f_status_t status = f_limit_process(1, 1, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_limit_process__works(void **state) { diff --git a/level_0/f_limit/tests/unit/c/test-limit-process.h b/level_0/f_limit/tests/unit/c/test-limit-process.h index 783f618..f746b08 100644 --- a/level_0/f_limit/tests/unit/c/test-limit-process.h +++ b/level_0/f_limit/tests/unit/c/test-limit-process.h @@ -22,9 +22,7 @@ extern void test__f_limit_process__fails(void **state); * * @see f_limit_process() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_limit_process__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_limit_process__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_memory/tests/unit/c/test-memory-adjust.c b/level_0/f_memory/tests/unit/c/test-memory-adjust.c index 04b911e..103a3fe 100644 --- a/level_0/f_memory/tests/unit/c/test-memory-adjust.c +++ b/level_0/f_memory/tests/unit/c/test-memory-adjust.c @@ -5,22 +5,20 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_memory_adjust__parameter_checking(void **state) { +void test__f_memory_adjust__parameter_checking(void **state) { - { - const f_status_t status = f_memory_adjust(1, 4, 0, 0); + { + const f_status_t status = f_memory_adjust(1, 4, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); + } - { - const f_status_t status = f_memory_adjust(1, 4, 1, 0); + { + const f_status_t status = f_memory_adjust(1, 4, 1, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_memory_adjust__works(void **state) { diff --git a/level_0/f_memory/tests/unit/c/test-memory-adjust.h b/level_0/f_memory/tests/unit/c/test-memory-adjust.h index 534080e..7436da5 100644 --- a/level_0/f_memory/tests/unit/c/test-memory-adjust.h +++ b/level_0/f_memory/tests/unit/c/test-memory-adjust.h @@ -15,9 +15,7 @@ * * @see f_memory_adjust() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_memory_adjust__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_memory_adjust__parameter_checking(void **state); /** * Test that reallocation works. diff --git a/level_0/f_memory/tests/unit/c/test-memory-delete.c b/level_0/f_memory/tests/unit/c/test-memory-delete.c index 44522d3..1caf20e 100644 --- a/level_0/f_memory/tests/unit/c/test-memory-delete.c +++ b/level_0/f_memory/tests/unit/c/test-memory-delete.c @@ -95,16 +95,14 @@ void test__f_memory_delete__frees_resized_memory(void **state) { } } -#ifndef _di_level_0_parameter_checking_ - void test__f_memory_delete__parameter_checking(void **state) { +void test__f_memory_delete__parameter_checking(void **state) { - { - const f_status_t status = f_memory_delete(4, 0, 0); + { + const f_status_t status = f_memory_delete(4, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} #ifdef __cplusplus } // extern "C" diff --git a/level_0/f_memory/tests/unit/c/test-memory-delete.h b/level_0/f_memory/tests/unit/c/test-memory-delete.h index fe9626c..b840a32 100644 --- a/level_0/f_memory/tests/unit/c/test-memory-delete.h +++ b/level_0/f_memory/tests/unit/c/test-memory-delete.h @@ -49,8 +49,6 @@ extern void test__f_memory_delete__frees_resized_memory(void **state); * * @see f_memory_delete() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_memory_delete__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_memory_delete__parameter_checking(void **state); #endif // _TEST__F_memory__delete diff --git a/level_0/f_memory/tests/unit/c/test-memory-destroy.c b/level_0/f_memory/tests/unit/c/test-memory-destroy.c index 9b844ee..a70a340 100644 --- a/level_0/f_memory/tests/unit/c/test-memory-destroy.c +++ b/level_0/f_memory/tests/unit/c/test-memory-destroy.c @@ -95,16 +95,14 @@ void test__f_memory_destroy__frees_resized_memory(void **state) { } } -#ifndef _di_level_0_parameter_checking_ - void test__f_memory_destroy__parameter_checking(void **state) { +void test__f_memory_destroy__parameter_checking(void **state) { - { - const f_status_t status = f_memory_destroy(4, 0, 0); + { + const f_status_t status = f_memory_destroy(4, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} #ifdef __cplusplus } // extern "C" diff --git a/level_0/f_memory/tests/unit/c/test-memory-destroy.h b/level_0/f_memory/tests/unit/c/test-memory-destroy.h index 561aec2..ab9d4b1 100644 --- a/level_0/f_memory/tests/unit/c/test-memory-destroy.h +++ b/level_0/f_memory/tests/unit/c/test-memory-destroy.h @@ -49,8 +49,6 @@ extern void test__f_memory_destroy__frees_resized_memory(void **state); * * @see f_memory_destroy() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_memory_destroy__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_memory_destroy__parameter_checking(void **state); #endif // _TEST__F_memory__destroy diff --git a/level_0/f_memory/tests/unit/c/test-memory-new.c b/level_0/f_memory/tests/unit/c/test-memory-new.c index 66d3a46..1b91af3 100644 --- a/level_0/f_memory/tests/unit/c/test-memory-new.c +++ b/level_0/f_memory/tests/unit/c/test-memory-new.c @@ -5,16 +5,14 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_memory_new__parameter_checking(void **state) { +void test__f_memory_new__parameter_checking(void **state) { - { - const f_status_t status = f_memory_new(1, 0, 0); + { + const f_status_t status = f_memory_new(1, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_memory_new__works(void **state) { diff --git a/level_0/f_memory/tests/unit/c/test-memory-new.h b/level_0/f_memory/tests/unit/c/test-memory-new.h index a3ab867..4fdb6d3 100644 --- a/level_0/f_memory/tests/unit/c/test-memory-new.h +++ b/level_0/f_memory/tests/unit/c/test-memory-new.h @@ -15,9 +15,7 @@ * * @see f_memory_new() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_memory_new__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_memory_new__parameter_checking(void **state); /** * Test that allocation works. diff --git a/level_0/f_memory/tests/unit/c/test-memory-new_aligned.c b/level_0/f_memory/tests/unit/c/test-memory-new_aligned.c index 990a7b0..34c4dab 100644 --- a/level_0/f_memory/tests/unit/c/test-memory-new_aligned.c +++ b/level_0/f_memory/tests/unit/c/test-memory-new_aligned.c @@ -5,16 +5,14 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_memory_new_aligned__parameter_checking(void **state) { +void test__f_memory_new_aligned__parameter_checking(void **state) { - { - const f_status_t status = f_memory_new_aligned(1, 0, 0); + { + const f_status_t status = f_memory_new_aligned(1, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_memory_new_aligned__works(void **state) { diff --git a/level_0/f_memory/tests/unit/c/test-memory-new_aligned.h b/level_0/f_memory/tests/unit/c/test-memory-new_aligned.h index 9b520f6..8c4e6e9 100644 --- a/level_0/f_memory/tests/unit/c/test-memory-new_aligned.h +++ b/level_0/f_memory/tests/unit/c/test-memory-new_aligned.h @@ -15,9 +15,7 @@ * * @see f_memory_new_aligned() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_memory_new_aligned__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_memory_new_aligned__parameter_checking(void **state); /** * Test that allocation works. diff --git a/level_0/f_memory/tests/unit/c/test-memory-resize.c b/level_0/f_memory/tests/unit/c/test-memory-resize.c index 4ea57d8..4fa5c6c 100644 --- a/level_0/f_memory/tests/unit/c/test-memory-resize.c +++ b/level_0/f_memory/tests/unit/c/test-memory-resize.c @@ -5,22 +5,20 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_memory_resize__parameter_checking(void **state) { +void test__f_memory_resize__parameter_checking(void **state) { - { - const f_status_t status = f_memory_resize(1, 4, 0, 0); + { + const f_status_t status = f_memory_resize(1, 4, 0, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); + } - { - const f_status_t status = f_memory_resize(1, 4, 1, 0); + { + const f_status_t status = f_memory_resize(1, 4, 1, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_memory_resize__works(void **state) { diff --git a/level_0/f_memory/tests/unit/c/test-memory-resize.h b/level_0/f_memory/tests/unit/c/test-memory-resize.h index 58efe23..ca8c5b6 100644 --- a/level_0/f_memory/tests/unit/c/test-memory-resize.h +++ b/level_0/f_memory/tests/unit/c/test-memory-resize.h @@ -15,9 +15,7 @@ * * @see f_memory_resize() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_memory_resize__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_memory_resize__parameter_checking(void **state); /** * Test that reallocation works. diff --git a/level_0/f_path/tests/unit/c/test-path-current.c b/level_0/f_path/tests/unit/c/test-path-current.c index e592b90..56c7ba9 100644 --- a/level_0/f_path/tests/unit/c/test-path-current.c +++ b/level_0/f_path/tests/unit/c/test-path-current.c @@ -87,16 +87,14 @@ void test__f_path_current__fails(void **state) { f_string_dynamic_resize(0, &destination); } -#ifndef _di_level_0_parameter_checking_ - void test__f_path_current__parameter_checking(void **state) { +void test__f_path_current__parameter_checking(void **state) { - { - const f_status_t status = f_path_current(F_false, 0); + { + const f_status_t status = f_path_current(F_false, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_path_current__works(void **state) { diff --git a/level_0/f_path/tests/unit/c/test-path-current.h b/level_0/f_path/tests/unit/c/test-path-current.h index a9ff7d3..1708432 100644 --- a/level_0/f_path/tests/unit/c/test-path-current.h +++ b/level_0/f_path/tests/unit/c/test-path-current.h @@ -22,9 +22,7 @@ extern void test__f_path_current__fails(void **state); * * @see f_path_current() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_path_current__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_path_current__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_path/tests/unit/c/test-path-directory_cleanup.c b/level_0/f_path/tests/unit/c/test-path-directory_cleanup.c index 889f038..9ead9b9 100644 --- a/level_0/f_path/tests/unit/c/test-path-directory_cleanup.c +++ b/level_0/f_path/tests/unit/c/test-path-directory_cleanup.c @@ -5,18 +5,16 @@ extern "C" { #endif -#ifndef _di_level_0_parameter_checking_ - void test__f_path_directory_cleanup__parameter_checking(void **state) { +void test__f_path_directory_cleanup__parameter_checking(void **state) { - const f_string_static_t path = macro_f_string_static_t_initialize("test", 0, 4); + const f_string_static_t path = macro_f_string_static_t_initialize("test", 0, 4); - { - const f_status_t status = f_path_directory_cleanup(path, 0); + { + const f_status_t status = f_path_directory_cleanup(path, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_path_directory_cleanup__works(void **state) { diff --git a/level_0/f_path/tests/unit/c/test-path-directory_cleanup.h b/level_0/f_path/tests/unit/c/test-path-directory_cleanup.h index 6c64516..2b67a89 100644 --- a/level_0/f_path/tests/unit/c/test-path-directory_cleanup.h +++ b/level_0/f_path/tests/unit/c/test-path-directory_cleanup.h @@ -15,9 +15,7 @@ * * @see f_path_directory_cleanup() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_path_directory_cleanup__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_path_directory_cleanup__parameter_checking(void **state); /** * Test that function works. diff --git a/level_0/f_path/tests/unit/c/test-path-real.c b/level_0/f_path/tests/unit/c/test-path-real.c index 7cf24c3..b6d2974 100644 --- a/level_0/f_path/tests/unit/c/test-path-real.c +++ b/level_0/f_path/tests/unit/c/test-path-real.c @@ -48,18 +48,16 @@ void test__f_path_real__fails(void **state) { f_string_dynamic_resize(0, &destination); } -#ifndef _di_level_0_parameter_checking_ - void test__f_path_real__parameter_checking(void **state) { +void test__f_path_real__parameter_checking(void **state) { - const f_string_static_t path = macro_f_string_static_t_initialize("test", 0, 4); + const f_string_static_t path = macro_f_string_static_t_initialize("test", 0, 4); - { - const f_status_t status = f_path_real(path, 0); + { + const f_status_t status = f_path_real(path, 0); - assert_int_equal(status, F_status_set_error(F_parameter)); - } + assert_int_equal(status, F_status_set_error(F_parameter)); } -#endif // _di_level_0_parameter_checking_ +} void test__f_path_real__works(void **state) { diff --git a/level_0/f_path/tests/unit/c/test-path-real.h b/level_0/f_path/tests/unit/c/test-path-real.h index c6af1ba..794eaac 100644 --- a/level_0/f_path/tests/unit/c/test-path-real.h +++ b/level_0/f_path/tests/unit/c/test-path-real.h @@ -22,9 +22,7 @@ extern void test__f_path_real__fails(void **state); * * @see f_path_real() */ -#ifndef _di_level_0_parameter_checking_ - extern void test__f_path_real__parameter_checking(void **state); -#endif // _di_level_0_parameter_checking_ +extern void test__f_path_real__parameter_checking(void **state); /** * Test that function works. -- 1.8.3.1