diff --git a/build/test/cache/defines_dependency.yml b/build/test/cache/defines_dependency.yml new file mode 100644 index 0000000..276aae5 --- /dev/null +++ b/build/test/cache/defines_dependency.yml @@ -0,0 +1,7 @@ +--- +src/ageinseconds.c: +- TEST +src/minirechner.c: +- TEST +src/zahlenraten.c: +- TEST diff --git a/build/test/cache/input.yml b/build/test/cache/input.yml new file mode 100644 index 0000000..dcb9748 --- /dev/null +++ b/build/test/cache/input.yml @@ -0,0 +1,278 @@ +--- +:project: + :use_exceptions: false + :use_mocks: true + :compile_threads: 1 + :test_threads: 1 + :use_test_preprocessor: true + :use_preprocessor_directives: false + :use_deep_dependencies: false + :generate_deep_dependencies: true + :auto_link_deep_dependencies: false + :test_file_prefix: test_ + :options_paths: [] + :release_build: true + :use_auxiliary_dependencies: true + :build_root: build + :which_ceedling: gem + :ceedling_version: 0.31.1 + :default_tasks: + - test:all +:release_build: + :use_assembly: false + :artifacts: [] + :output: theluckyaliens +:paths: + :test: + - "+:test/**" + - "-:test/support" + :source: + - src/** + :support: + - test/support + :include: [] + :libraries: [] + :test_toolchain_include: [] + :release_toolchain_include: [] +:files: + :test: [] + :source: [] + :assembly: [] + :support: [] + :include: [] +:environment: +- :rake_columns: '120' +:defines: + :test: + - &1 [] + - TEST + :test_preprocess: + - *1 + - TEST + :release: [] + :release_preprocess: [] + :use_test_definition: false + :common: [] +:libraries: + :flag: "-l${1}" + :path_flag: "-L ${1}" + :test: [] + :test_preprocess: [] + :release: [] + :release_preprocess: [] + :placement: :end + :system: + - m +:flags: {} +:extension: + :header: ".h" + :source: ".c" + :assembly: ".s" + :object: ".o" + :libraries: + - ".a" + - ".so" + :executable: ".out" + :map: ".map" + :list: ".lst" + :testpass: ".pass" + :testfail: ".fail" + :dependencies: ".d" +:unity: + :vendor_path: C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor + :defines: [] +:cmock: + :vendor_path: C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor + :defines: [] + :includes: [] + :mock_prefix: mock_ + :when_no_prototypes: :warn + :enforce_strict_ordering: true + :plugins: + - :ignore + - :callback + :treat_as: + uint8: HEX8 + uint16: HEX16 + uint32: UINT32 + int8: INT8 + bool: UINT8 + :mock_path: build/test/mocks + :verbosity: 3 + :unity_helper: false +:cexception: + :vendor_path: C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor + :defines: [] +:test_runner: + :includes: [] + :file_suffix: _runner +:tools: + :test_compiler: + :executable: gcc.exe + :name: default_test_compiler + :stderr_redirect: :none + :background_exec: :none + :optional: false + :arguments: + - '' + - '' + - -I"$": COLLECTION_PATHS_TEST_SUPPORT_SOURCE_INCLUDE_VENDOR + - -I"$": COLLECTION_PATHS_TEST_TOOLCHAIN_INCLUDE + - "-D$": COLLECTION_DEFINES_TEST_AND_VENDOR + - "-DGNU_COMPILER" + - "-g" + - '' + - -c "${1}" + - -o "${2}" + - "-MMD" + - -MF "${4}" + :test_fixture: + :executable: "${1}" + :name: default_test_fixture + :stderr_redirect: :auto + :background_exec: :none + :optional: false + :arguments: [] + :test_linker: + :executable: gcc.exe + :name: default_test_linker + :stderr_redirect: :none + :background_exec: :none + :optional: false + :arguments: + - '' + - '' + - '' + - '"${1}"' + - "${5}" + - -o "${2}" + - '' + - "${4}" + - '' + :test_file_preprocessor: + :executable: gcc.exe + :name: default_test_file_preprocessor + :stderr_redirect: :none + :background_exec: :none + :optional: false + :arguments: + - '' + - '' + - "-E" + - -I"$": COLLECTION_PATHS_TEST_SUPPORT_SOURCE_INCLUDE_VENDOR + - -I"$": COLLECTION_PATHS_TEST_TOOLCHAIN_INCLUDE + - "-D$": COLLECTION_DEFINES_TEST_AND_VENDOR + - "-D$": DEFINES_TEST_PREPROCESS + - "-DGNU_COMPILER" + - '"${1}"' + - -o "${2}" + :test_file_preprocessor_directives: + :executable: gcc.exe + :name: default_test_file_preprocessor_directives + :stderr_redirect: :none + :background_exec: :none + :optional: false + :arguments: + - "-E" + - -I"$": COLLECTION_PATHS_TEST_SUPPORT_SOURCE_INCLUDE_VENDOR + - -I"$": COLLECTION_PATHS_TEST_TOOLCHAIN_INCLUDE + - "-D$": COLLECTION_DEFINES_TEST_AND_VENDOR + - "-D$": DEFINES_TEST_PREPROCESS + - "-DGNU_COMPILER" + - "-fdirectives-only" + - '"${1}"' + - -o "${2}" + :test_includes_preprocessor: + :executable: gcc.exe + :name: default_test_includes_preprocessor + :stderr_redirect: :none + :background_exec: :none + :optional: false + :arguments: + - '' + - '' + - "-E" + - "-MM" + - "-MG" + - -I"$": COLLECTION_PATHS_TEST_SUPPORT_SOURCE_INCLUDE_VENDOR + - -I"$": COLLECTION_PATHS_TEST_TOOLCHAIN_INCLUDE + - "-D$": COLLECTION_DEFINES_TEST_AND_VENDOR + - "-D$": DEFINES_TEST_PREPROCESS + - "-DGNU_COMPILER" + - '"${1}"' + :release_compiler: + :executable: gcc.exe + :name: default_release_compiler + :stderr_redirect: :none + :background_exec: :none + :optional: false + :arguments: + - '' + - '' + - -I"$": COLLECTION_PATHS_SOURCE_INCLUDE_VENDOR + - -I"$": COLLECTION_PATHS_RELEASE_TOOLCHAIN_INCLUDE + - "-D$": COLLECTION_DEFINES_RELEASE_AND_VENDOR + - "-DGNU_COMPILER" + - '' + - -c "${1}" + - -o "${2}" + - "-MMD" + - -MF "${4}" + :release_linker: + :executable: gcc.exe + :name: default_release_linker + :stderr_redirect: :none + :background_exec: :none + :optional: false + :arguments: + - '' + - '' + - '' + - '"${1}"' + - "${5}" + - -o "${2}" + - '' + - "${4}" + - '' +:test_compiler: + :arguments: [] +:test_linker: + :arguments: [] +:test_fixture: + :arguments: [] + :link_objects: [] +:test_includes_preprocessor: + :arguments: [] +:test_file_preprocessor: + :arguments: [] +:test_file_preprocessor_directives: + :arguments: [] +:test_dependencies_generator: + :arguments: [] +:release_compiler: + :arguments: [] +:release_linker: + :arguments: [] +:release_assembler: + :arguments: [] +:release_dependencies_generator: + :arguments: [] +:plugins: + :load_paths: + - C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/lib/../plugins + :enabled: + - stdout_pretty_tests_report + - module_generator + :display_raw_test_results: false + :stdout_pretty_tests_report_path: C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/lib/../plugins/stdout_pretty_tests_report + :module_generator_path: C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/lib/../plugins/module_generator +:gcov: + :reports: + - HtmlDetailed + :gcovr: + :html_medium_threshold: 75 + :html_high_threshold: 90 +:module_generator: + :project_root: "./" + :source_root: src/ + :test_root: test/ diff --git a/build/test/cache/test_ageinseconds.c b/build/test/cache/test_ageinseconds.c new file mode 100644 index 0000000..3aadcbf --- /dev/null +++ b/build/test/cache/test_ageinseconds.c @@ -0,0 +1,77 @@ +#include "src/ageinseconds.h" +#include "C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity.h" + + + + + + + + +void setUp(void) + +{ + +} + + + +void tearDown(void) + +{ + +} + + + + + +void test_ageinseconds_45_in_sekunden(void) + +{ + + float result = sekunden(45); + + UnityAssertEqualNumber((UNITY_INT)((1419120000)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(19), UNITY_DISPLAY_STYLE_INT); + +} + + + + + +void test_ageinseconds_23_in_minuten(void) + +{ + + float result = minuten(23); + + UnityAssertEqualNumber((UNITY_INT)((12088800)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(26), UNITY_DISPLAY_STYLE_INT); + +} + + + + + +void test_ageinseconds_34_in_stunden(void) + +{ + + float result = stunden(34); + + UnityAssertEqualNumber((UNITY_INT)((297840)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(33), UNITY_DISPLAY_STYLE_INT); + +} diff --git a/build/test/cache/test_minirechner.c b/build/test/cache/test_minirechner.c new file mode 100644 index 0000000..bfd4d20 --- /dev/null +++ b/build/test/cache/test_minirechner.c @@ -0,0 +1,325 @@ +#include "src/minirechner.h" +#include "C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity.h" + + + + + + + + +void setUp(void) + +{ + +} + + + +void tearDown(void) + +{ + +} + + + + + +void test_minitaschenrechner_3_plus_4(void) + +{ + + float result = addieren(3, 4); + + UnityAssertEqualNumber((UNITY_INT)((7)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(19), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_float_plus_float(void) + +{ + + float result = addieren(3.1, 4.2); + + UnityAssertEqualNumber((UNITY_INT)((7.3)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(25), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_minus1_plus_minus3(void) + +{ + + float result = addieren(-1, -3); + + UnityAssertEqualNumber((UNITY_INT)((-4)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(31), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_0_plus_2(void) + +{ + + float result = addieren(0, 2); + + UnityAssertEqualNumber((UNITY_INT)((2)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(37), UNITY_DISPLAY_STYLE_INT); + +} + + + + + +void test_minitaschenrechner_5_minus_2(void) + +{ + + float result = subtrahieren(5, 2); + + UnityAssertEqualNumber((UNITY_INT)((3)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(44), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_float_minus_float(void) + +{ + + float result = subtrahieren(2.7, 1.3); + + UnityAssertEqualNumber((UNITY_INT)((1.4)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(50), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_minus7_minus_minus3(void) + +{ + + float result = subtrahieren(-7, -3); + + UnityAssertEqualNumber((UNITY_INT)((-4)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(56), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_4_minus_0(void) + +{ + + float result = subtrahieren(4, 0); + + UnityAssertEqualNumber((UNITY_INT)((4)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(62), UNITY_DISPLAY_STYLE_INT); + +} + + + + + +void test_minitaschenrechner_8_mal_3(void) + +{ + + float result = multiplizieren(8, 3); + + UnityAssertEqualNumber((UNITY_INT)((24)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(69), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_minus3_mal_minus4(void) + +{ + + float result = multiplizieren(-3, -4); + + UnityAssertEqualNumber((UNITY_INT)((12)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(75), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_0_mal_5(void) + +{ + + float result = multiplizieren(0, 5); + + UnityAssertEqualNumber((UNITY_INT)((0)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(81), UNITY_DISPLAY_STYLE_INT); + +} + + + + + +void test_minitaschenrechner_9_durch_3(void) + +{ + + float result = dividieren(9, 3); + + UnityAssertEqualNumber((UNITY_INT)((3)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(88), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_minus6_durch_minus2(void) + +{ + + float result = dividieren(-6, -2); + + UnityAssertEqualNumber((UNITY_INT)((3)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(94), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_0_durch_5(void) + +{ + + float result = dividieren(0, 5); + + UnityAssertEqualNumber((UNITY_INT)((0)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(100), UNITY_DISPLAY_STYLE_INT); + +} + + + + + +void test_minitaschenrechner_14_rest_5(void) + +{ + + float result = rest(14, 5); + + UnityAssertEqualNumber((UNITY_INT)((4)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(107), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_1_rest_7(void) + +{ + + float result = rest(0, 7); + + UnityAssertEqualNumber((UNITY_INT)((0)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(113), UNITY_DISPLAY_STYLE_INT); + +} + + + + + +void test_minitaschenrechner_120_groesster_gemeinsammer_teiler_30(void) + +{ + + float result = groesster_gemeinsammer_teiler(120, 30); + + UnityAssertEqualNumber((UNITY_INT)((30)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(120), UNITY_DISPLAY_STYLE_INT); + +} + + + + + +void test_minitaschenrechner_120_kleinstes_gemeinsammes_vielfaches_50(void) + +{ + + float result = kleinstes_gemeinsammes_vielfaches(120, 50); + + UnityAssertEqualNumber((UNITY_INT)((600)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(127), UNITY_DISPLAY_STYLE_INT); + +} diff --git a/build/test/cache/test_zahlenraten.c b/build/test/cache/test_zahlenraten.c new file mode 100644 index 0000000..91996af --- /dev/null +++ b/build/test/cache/test_zahlenraten.c @@ -0,0 +1,45 @@ +#include "src/zahlenraten.h" +#include "C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity.h" + + + + + + + + +void setUp(void) + +{ + +} + + + +void tearDown(void) + +{ + +} + + + +void test_zahlenraten_gib_zufallszahl(void) + +{ + + int result = gib_zufallszahl(); + + UnityAssertGreaterOrLessOrEqualNumber((UNITY_INT)((0)), (UNITY_INT)((result)), UNITY_GREATER_THAN, ( + + ((void *)0) + + ), (UNITY_UINT)(18), UNITY_DISPLAY_STYLE_INT); + + UnityAssertGreaterOrLessOrEqualNumber((UNITY_INT)((101)), (UNITY_INT)((result)), UNITY_SMALLER_THAN, ( + + ((void *)0) + + ), (UNITY_UINT)(19), UNITY_DISPLAY_STYLE_INT); + +} diff --git a/build/test/dependencies/ageinseconds.d b/build/test/dependencies/ageinseconds.d new file mode 100644 index 0000000..6ae928f --- /dev/null +++ b/build/test/dependencies/ageinseconds.d @@ -0,0 +1 @@ +build/test/out/c/ageinseconds.o: src/ageinseconds.c src/ageinseconds.h diff --git a/build/test/dependencies/cmock.d b/build/test/dependencies/cmock.d new file mode 100644 index 0000000..bdf4cc9 --- /dev/null +++ b/build/test/dependencies/cmock.d @@ -0,0 +1,6 @@ +build/test/out/c/cmock.o: \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/cmock/src/cmock.c \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/cmock/src/cmock.h \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/cmock/src/cmock_internals.h \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity.h \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity_internals.h diff --git a/build/test/dependencies/minirechner.d b/build/test/dependencies/minirechner.d new file mode 100644 index 0000000..ac14042 --- /dev/null +++ b/build/test/dependencies/minirechner.d @@ -0,0 +1 @@ +build/test/out/c/minirechner.o: src/minirechner.c src/minirechner.h diff --git a/build/test/dependencies/test_ageinseconds.d b/build/test/dependencies/test_ageinseconds.d new file mode 100644 index 0000000..df78c5a --- /dev/null +++ b/build/test/dependencies/test_ageinseconds.d @@ -0,0 +1,4 @@ +build/test/out/c/test_ageinseconds.o: test/test_ageinseconds.c \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity.h \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity_internals.h \ + src/ageinseconds.h diff --git a/build/test/dependencies/test_ageinseconds_runner.d b/build/test/dependencies/test_ageinseconds_runner.d new file mode 100644 index 0000000..a126138 --- /dev/null +++ b/build/test/dependencies/test_ageinseconds_runner.d @@ -0,0 +1,4 @@ +build/test/out/c/test_ageinseconds_runner.o: \ + build/test/runners/test_ageinseconds_runner.c \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity.h \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity_internals.h diff --git a/build/test/dependencies/test_minirechner.d b/build/test/dependencies/test_minirechner.d new file mode 100644 index 0000000..57cc195 --- /dev/null +++ b/build/test/dependencies/test_minirechner.d @@ -0,0 +1,4 @@ +build/test/out/c/test_minirechner.o: test/test_minirechner.c \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity.h \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity_internals.h \ + src/minirechner.h diff --git a/build/test/dependencies/test_minirechner_runner.d b/build/test/dependencies/test_minirechner_runner.d new file mode 100644 index 0000000..c85cb96 --- /dev/null +++ b/build/test/dependencies/test_minirechner_runner.d @@ -0,0 +1,4 @@ +build/test/out/c/test_minirechner_runner.o: \ + build/test/runners/test_minirechner_runner.c \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity.h \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity_internals.h diff --git a/build/test/dependencies/test_zahlenraten.d b/build/test/dependencies/test_zahlenraten.d new file mode 100644 index 0000000..0e8ebfc --- /dev/null +++ b/build/test/dependencies/test_zahlenraten.d @@ -0,0 +1,4 @@ +build/test/out/c/test_zahlenraten.o: test/test_zahlenraten.c \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity.h \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity_internals.h \ + src/zahlenraten.h diff --git a/build/test/dependencies/test_zahlenraten_runner.d b/build/test/dependencies/test_zahlenraten_runner.d new file mode 100644 index 0000000..6186b44 --- /dev/null +++ b/build/test/dependencies/test_zahlenraten_runner.d @@ -0,0 +1,4 @@ +build/test/out/c/test_zahlenraten_runner.o: \ + build/test/runners/test_zahlenraten_runner.c \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity.h \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity_internals.h diff --git a/build/test/dependencies/unity.d b/build/test/dependencies/unity.d new file mode 100644 index 0000000..0baf56c --- /dev/null +++ b/build/test/dependencies/unity.d @@ -0,0 +1,4 @@ +build/test/out/c/unity.o: \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity.c \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity.h \ + C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity_internals.h diff --git a/build/test/dependencies/zahlenraten.d b/build/test/dependencies/zahlenraten.d new file mode 100644 index 0000000..cff70af --- /dev/null +++ b/build/test/dependencies/zahlenraten.d @@ -0,0 +1 @@ +build/test/out/c/zahlenraten.o: src/zahlenraten.c diff --git a/build/test/out/c/ageinseconds.o b/build/test/out/c/ageinseconds.o new file mode 100644 index 0000000..fb15a6e Binary files /dev/null and b/build/test/out/c/ageinseconds.o differ diff --git a/build/test/out/c/cmock.o b/build/test/out/c/cmock.o new file mode 100644 index 0000000..ba789c7 Binary files /dev/null and b/build/test/out/c/cmock.o differ diff --git a/build/test/out/c/minirechner.o b/build/test/out/c/minirechner.o new file mode 100644 index 0000000..572116a Binary files /dev/null and b/build/test/out/c/minirechner.o differ diff --git a/build/test/out/c/test_ageinseconds.o b/build/test/out/c/test_ageinseconds.o new file mode 100644 index 0000000..f22eb66 Binary files /dev/null and b/build/test/out/c/test_ageinseconds.o differ diff --git a/build/test/out/c/test_ageinseconds_runner.o b/build/test/out/c/test_ageinseconds_runner.o new file mode 100644 index 0000000..fd89869 Binary files /dev/null and b/build/test/out/c/test_ageinseconds_runner.o differ diff --git a/build/test/out/c/test_minirechner.o b/build/test/out/c/test_minirechner.o new file mode 100644 index 0000000..465ba67 Binary files /dev/null and b/build/test/out/c/test_minirechner.o differ diff --git a/build/test/out/c/test_minirechner_runner.o b/build/test/out/c/test_minirechner_runner.o new file mode 100644 index 0000000..e340941 Binary files /dev/null and b/build/test/out/c/test_minirechner_runner.o differ diff --git a/build/test/out/c/test_zahlenraten.o b/build/test/out/c/test_zahlenraten.o new file mode 100644 index 0000000..be2aff1 Binary files /dev/null and b/build/test/out/c/test_zahlenraten.o differ diff --git a/build/test/out/c/test_zahlenraten_runner.o b/build/test/out/c/test_zahlenraten_runner.o new file mode 100644 index 0000000..0b14252 Binary files /dev/null and b/build/test/out/c/test_zahlenraten_runner.o differ diff --git a/build/test/out/c/unity.o b/build/test/out/c/unity.o new file mode 100644 index 0000000..01f6c72 Binary files /dev/null and b/build/test/out/c/unity.o differ diff --git a/build/test/out/c/zahlenraten.o b/build/test/out/c/zahlenraten.o new file mode 100644 index 0000000..7214aaf Binary files /dev/null and b/build/test/out/c/zahlenraten.o differ diff --git a/build/test/out/test_ageinseconds.out b/build/test/out/test_ageinseconds.out new file mode 100644 index 0000000..c56e3fe Binary files /dev/null and b/build/test/out/test_ageinseconds.out differ diff --git a/build/test/out/test_minirechner.out b/build/test/out/test_minirechner.out new file mode 100644 index 0000000..09ee708 Binary files /dev/null and b/build/test/out/test_minirechner.out differ diff --git a/build/test/out/test_zahlenraten.out b/build/test/out/test_zahlenraten.out new file mode 100644 index 0000000..557c303 Binary files /dev/null and b/build/test/out/test_zahlenraten.out differ diff --git a/build/test/preprocess/files/test_ageinseconds.c b/build/test/preprocess/files/test_ageinseconds.c new file mode 100644 index 0000000..3aadcbf --- /dev/null +++ b/build/test/preprocess/files/test_ageinseconds.c @@ -0,0 +1,77 @@ +#include "src/ageinseconds.h" +#include "C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity.h" + + + + + + + + +void setUp(void) + +{ + +} + + + +void tearDown(void) + +{ + +} + + + + + +void test_ageinseconds_45_in_sekunden(void) + +{ + + float result = sekunden(45); + + UnityAssertEqualNumber((UNITY_INT)((1419120000)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(19), UNITY_DISPLAY_STYLE_INT); + +} + + + + + +void test_ageinseconds_23_in_minuten(void) + +{ + + float result = minuten(23); + + UnityAssertEqualNumber((UNITY_INT)((12088800)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(26), UNITY_DISPLAY_STYLE_INT); + +} + + + + + +void test_ageinseconds_34_in_stunden(void) + +{ + + float result = stunden(34); + + UnityAssertEqualNumber((UNITY_INT)((297840)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(33), UNITY_DISPLAY_STYLE_INT); + +} diff --git a/build/test/preprocess/files/test_minirechner.c b/build/test/preprocess/files/test_minirechner.c new file mode 100644 index 0000000..bfd4d20 --- /dev/null +++ b/build/test/preprocess/files/test_minirechner.c @@ -0,0 +1,325 @@ +#include "src/minirechner.h" +#include "C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity.h" + + + + + + + + +void setUp(void) + +{ + +} + + + +void tearDown(void) + +{ + +} + + + + + +void test_minitaschenrechner_3_plus_4(void) + +{ + + float result = addieren(3, 4); + + UnityAssertEqualNumber((UNITY_INT)((7)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(19), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_float_plus_float(void) + +{ + + float result = addieren(3.1, 4.2); + + UnityAssertEqualNumber((UNITY_INT)((7.3)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(25), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_minus1_plus_minus3(void) + +{ + + float result = addieren(-1, -3); + + UnityAssertEqualNumber((UNITY_INT)((-4)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(31), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_0_plus_2(void) + +{ + + float result = addieren(0, 2); + + UnityAssertEqualNumber((UNITY_INT)((2)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(37), UNITY_DISPLAY_STYLE_INT); + +} + + + + + +void test_minitaschenrechner_5_minus_2(void) + +{ + + float result = subtrahieren(5, 2); + + UnityAssertEqualNumber((UNITY_INT)((3)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(44), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_float_minus_float(void) + +{ + + float result = subtrahieren(2.7, 1.3); + + UnityAssertEqualNumber((UNITY_INT)((1.4)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(50), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_minus7_minus_minus3(void) + +{ + + float result = subtrahieren(-7, -3); + + UnityAssertEqualNumber((UNITY_INT)((-4)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(56), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_4_minus_0(void) + +{ + + float result = subtrahieren(4, 0); + + UnityAssertEqualNumber((UNITY_INT)((4)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(62), UNITY_DISPLAY_STYLE_INT); + +} + + + + + +void test_minitaschenrechner_8_mal_3(void) + +{ + + float result = multiplizieren(8, 3); + + UnityAssertEqualNumber((UNITY_INT)((24)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(69), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_minus3_mal_minus4(void) + +{ + + float result = multiplizieren(-3, -4); + + UnityAssertEqualNumber((UNITY_INT)((12)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(75), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_0_mal_5(void) + +{ + + float result = multiplizieren(0, 5); + + UnityAssertEqualNumber((UNITY_INT)((0)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(81), UNITY_DISPLAY_STYLE_INT); + +} + + + + + +void test_minitaschenrechner_9_durch_3(void) + +{ + + float result = dividieren(9, 3); + + UnityAssertEqualNumber((UNITY_INT)((3)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(88), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_minus6_durch_minus2(void) + +{ + + float result = dividieren(-6, -2); + + UnityAssertEqualNumber((UNITY_INT)((3)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(94), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_0_durch_5(void) + +{ + + float result = dividieren(0, 5); + + UnityAssertEqualNumber((UNITY_INT)((0)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(100), UNITY_DISPLAY_STYLE_INT); + +} + + + + + +void test_minitaschenrechner_14_rest_5(void) + +{ + + float result = rest(14, 5); + + UnityAssertEqualNumber((UNITY_INT)((4)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(107), UNITY_DISPLAY_STYLE_INT); + +} + + + +void test_minitaschenrechner_1_rest_7(void) + +{ + + float result = rest(0, 7); + + UnityAssertEqualNumber((UNITY_INT)((0)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(113), UNITY_DISPLAY_STYLE_INT); + +} + + + + + +void test_minitaschenrechner_120_groesster_gemeinsammer_teiler_30(void) + +{ + + float result = groesster_gemeinsammer_teiler(120, 30); + + UnityAssertEqualNumber((UNITY_INT)((30)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(120), UNITY_DISPLAY_STYLE_INT); + +} + + + + + +void test_minitaschenrechner_120_kleinstes_gemeinsammes_vielfaches_50(void) + +{ + + float result = kleinstes_gemeinsammes_vielfaches(120, 50); + + UnityAssertEqualNumber((UNITY_INT)((600)), (UNITY_INT)((result)), ( + + ((void *)0) + + ), (UNITY_UINT)(127), UNITY_DISPLAY_STYLE_INT); + +} diff --git a/build/test/preprocess/files/test_zahlenraten.c b/build/test/preprocess/files/test_zahlenraten.c new file mode 100644 index 0000000..91996af --- /dev/null +++ b/build/test/preprocess/files/test_zahlenraten.c @@ -0,0 +1,45 @@ +#include "src/zahlenraten.h" +#include "C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity.h" + + + + + + + + +void setUp(void) + +{ + +} + + + +void tearDown(void) + +{ + +} + + + +void test_zahlenraten_gib_zufallszahl(void) + +{ + + int result = gib_zufallszahl(); + + UnityAssertGreaterOrLessOrEqualNumber((UNITY_INT)((0)), (UNITY_INT)((result)), UNITY_GREATER_THAN, ( + + ((void *)0) + + ), (UNITY_UINT)(18), UNITY_DISPLAY_STYLE_INT); + + UnityAssertGreaterOrLessOrEqualNumber((UNITY_INT)((101)), (UNITY_INT)((result)), UNITY_SMALLER_THAN, ( + + ((void *)0) + + ), (UNITY_UINT)(19), UNITY_DISPLAY_STYLE_INT); + +} diff --git a/build/test/preprocess/includes/test_ageinseconds.c b/build/test/preprocess/includes/test_ageinseconds.c new file mode 100644 index 0000000..72fad1a --- /dev/null +++ b/build/test/preprocess/includes/test_ageinseconds.c @@ -0,0 +1,3 @@ +--- +- C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity.h +- src/ageinseconds.h diff --git a/build/test/preprocess/includes/test_minirechner.c b/build/test/preprocess/includes/test_minirechner.c new file mode 100644 index 0000000..31bb6ec --- /dev/null +++ b/build/test/preprocess/includes/test_minirechner.c @@ -0,0 +1,3 @@ +--- +- C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity.h +- src/minirechner.h diff --git a/build/test/preprocess/includes/test_zahlenraten.c b/build/test/preprocess/includes/test_zahlenraten.c new file mode 100644 index 0000000..6296503 --- /dev/null +++ b/build/test/preprocess/includes/test_zahlenraten.c @@ -0,0 +1,3 @@ +--- +- C:/Ruby30-x64/lib/ruby/gems/3.0.0/gems/ceedling-0.31.1/vendor/unity/src/unity.h +- src/zahlenraten.h diff --git a/build/test/results/test_ageinseconds.pass b/build/test/results/test_ageinseconds.pass new file mode 100644 index 0000000..fffdc3a --- /dev/null +++ b/build/test/results/test_ageinseconds.pass @@ -0,0 +1,26 @@ +--- +:source: + :path: test + :file: test_ageinseconds.c +:successes: +- :test: test_ageinseconds_45_in_sekunden + :line: 16 + :message: '' + :unity_test_time: 0 +- :test: test_ageinseconds_23_in_minuten + :line: 23 + :message: '' + :unity_test_time: 0 +- :test: test_ageinseconds_34_in_stunden + :line: 30 + :message: '' + :unity_test_time: 0 +:failures: [] +:ignores: [] +:counts: + :total: 3 + :passed: 3 + :failed: 0 + :ignored: 0 +:stdout: [] +:time: 0.8361497999994754 diff --git a/build/test/results/test_minirechner.pass b/build/test/results/test_minirechner.pass new file mode 100644 index 0000000..7e7a215 --- /dev/null +++ b/build/test/results/test_minirechner.pass @@ -0,0 +1,86 @@ +--- +:source: + :path: test + :file: test_minirechner.c +:successes: +- :test: test_minitaschenrechner_3_plus_4 + :line: 16 + :message: '' + :unity_test_time: 0 +- :test: test_minitaschenrechner_float_plus_float + :line: 22 + :message: '' + :unity_test_time: 0 +- :test: test_minitaschenrechner_minus1_plus_minus3 + :line: 28 + :message: '' + :unity_test_time: 0 +- :test: test_minitaschenrechner_0_plus_2 + :line: 34 + :message: '' + :unity_test_time: 0 +- :test: test_minitaschenrechner_5_minus_2 + :line: 41 + :message: '' + :unity_test_time: 0 +- :test: test_minitaschenrechner_float_minus_float + :line: 47 + :message: '' + :unity_test_time: 0 +- :test: test_minitaschenrechner_minus7_minus_minus3 + :line: 53 + :message: '' + :unity_test_time: 0 +- :test: test_minitaschenrechner_4_minus_0 + :line: 59 + :message: '' + :unity_test_time: 0 +- :test: test_minitaschenrechner_8_mal_3 + :line: 66 + :message: '' + :unity_test_time: 0 +- :test: test_minitaschenrechner_minus3_mal_minus4 + :line: 72 + :message: '' + :unity_test_time: 0 +- :test: test_minitaschenrechner_0_mal_5 + :line: 78 + :message: '' + :unity_test_time: 0 +- :test: test_minitaschenrechner_9_durch_3 + :line: 85 + :message: '' + :unity_test_time: 0 +- :test: test_minitaschenrechner_minus6_durch_minus2 + :line: 91 + :message: '' + :unity_test_time: 0 +- :test: test_minitaschenrechner_0_durch_5 + :line: 97 + :message: '' + :unity_test_time: 0 +- :test: test_minitaschenrechner_14_rest_5 + :line: 104 + :message: '' + :unity_test_time: 0 +- :test: test_minitaschenrechner_1_rest_7 + :line: 110 + :message: '' + :unity_test_time: 0 +- :test: test_minitaschenrechner_120_groesster_gemeinsammer_teiler_30 + :line: 117 + :message: '' + :unity_test_time: 0 +- :test: test_minitaschenrechner_120_kleinstes_gemeinsammes_vielfaches_50 + :line: 124 + :message: '' + :unity_test_time: 0 +:failures: [] +:ignores: [] +:counts: + :total: 18 + :passed: 18 + :failed: 0 + :ignored: 0 +:stdout: [] +:time: 0.33068490000005113 diff --git a/build/test/results/test_zahlenraten.pass b/build/test/results/test_zahlenraten.pass new file mode 100644 index 0000000..15fdbb1 --- /dev/null +++ b/build/test/results/test_zahlenraten.pass @@ -0,0 +1,18 @@ +--- +:source: + :path: test + :file: test_zahlenraten.c +:successes: +- :test: test_zahlenraten_gib_zufallszahl + :line: 15 + :message: '' + :unity_test_time: 0 +:failures: [] +:ignores: [] +:counts: + :total: 1 + :passed: 1 + :failed: 0 + :ignored: 0 +:stdout: [] +:time: 0.31757349999952567 diff --git a/build/test/runners/test_ageinseconds_runner.c b/build/test/runners/test_ageinseconds_runner.c new file mode 100644 index 0000000..c5f9c51 --- /dev/null +++ b/build/test/runners/test_ageinseconds_runner.c @@ -0,0 +1,85 @@ +/* AUTOGENERATED FILE. DO NOT EDIT. */ + +/*=======Automagically Detected Files To Include=====*/ +#include "unity.h" + +int GlobalExpectCount; +int GlobalVerifyOrder; +char* GlobalOrderError; + +/*=======External Functions This Runner Calls=====*/ +extern void setUp(void); +extern void tearDown(void); +extern void test_ageinseconds_45_in_sekunden(void); +extern void test_ageinseconds_23_in_minuten(void); +extern void test_ageinseconds_34_in_stunden(void); + + +/*=======Mock Management=====*/ +static void CMock_Init(void) +{ + GlobalExpectCount = 0; + GlobalVerifyOrder = 0; + GlobalOrderError = NULL; +} +static void CMock_Verify(void) +{ +} +static void CMock_Destroy(void) +{ +} + +/*=======Test Reset Options=====*/ +void resetTest(void); +void resetTest(void) +{ + tearDown(); + CMock_Verify(); + CMock_Destroy(); + CMock_Init(); + setUp(); +} +void verifyTest(void); +void verifyTest(void) +{ + CMock_Verify(); +} + +/*=======Test Runner Used To Run Each Test=====*/ +static void run_test(UnityTestFunction func, const char* name, UNITY_LINE_TYPE line_num) +{ + Unity.CurrentTestName = name; + Unity.CurrentTestLineNumber = line_num; +#ifdef UNITY_USE_COMMAND_LINE_ARGS + if (!UnityTestMatches()) + return; +#endif + Unity.NumberOfTests++; + UNITY_CLR_DETAILS(); + UNITY_EXEC_TIME_START(); + CMock_Init(); + if (TEST_PROTECT()) + { + setUp(); + func(); + } + if (TEST_PROTECT()) + { + tearDown(); + CMock_Verify(); + } + CMock_Destroy(); + UNITY_EXEC_TIME_STOP(); + UnityConcludeTest(); +} + +/*=======MAIN=====*/ +int main(void) +{ + UnityBegin("test_ageinseconds.c"); + run_test(test_ageinseconds_45_in_sekunden, "test_ageinseconds_45_in_sekunden", 16); + run_test(test_ageinseconds_23_in_minuten, "test_ageinseconds_23_in_minuten", 23); + run_test(test_ageinseconds_34_in_stunden, "test_ageinseconds_34_in_stunden", 30); + + return UnityEnd(); +} diff --git a/build/test/runners/test_minirechner_runner.c b/build/test/runners/test_minirechner_runner.c new file mode 100644 index 0000000..4db8169 --- /dev/null +++ b/build/test/runners/test_minirechner_runner.c @@ -0,0 +1,115 @@ +/* AUTOGENERATED FILE. DO NOT EDIT. */ + +/*=======Automagically Detected Files To Include=====*/ +#include "unity.h" + +int GlobalExpectCount; +int GlobalVerifyOrder; +char* GlobalOrderError; + +/*=======External Functions This Runner Calls=====*/ +extern void setUp(void); +extern void tearDown(void); +extern void test_minitaschenrechner_3_plus_4(void); +extern void test_minitaschenrechner_float_plus_float(void); +extern void test_minitaschenrechner_minus1_plus_minus3(void); +extern void test_minitaschenrechner_0_plus_2(void); +extern void test_minitaschenrechner_5_minus_2(void); +extern void test_minitaschenrechner_float_minus_float(void); +extern void test_minitaschenrechner_minus7_minus_minus3(void); +extern void test_minitaschenrechner_4_minus_0(void); +extern void test_minitaschenrechner_8_mal_3(void); +extern void test_minitaschenrechner_minus3_mal_minus4(void); +extern void test_minitaschenrechner_0_mal_5(void); +extern void test_minitaschenrechner_9_durch_3(void); +extern void test_minitaschenrechner_minus6_durch_minus2(void); +extern void test_minitaschenrechner_0_durch_5(void); +extern void test_minitaschenrechner_14_rest_5(void); +extern void test_minitaschenrechner_1_rest_7(void); +extern void test_minitaschenrechner_120_groesster_gemeinsammer_teiler_30(void); +extern void test_minitaschenrechner_120_kleinstes_gemeinsammes_vielfaches_50(void); + + +/*=======Mock Management=====*/ +static void CMock_Init(void) +{ + GlobalExpectCount = 0; + GlobalVerifyOrder = 0; + GlobalOrderError = NULL; +} +static void CMock_Verify(void) +{ +} +static void CMock_Destroy(void) +{ +} + +/*=======Test Reset Options=====*/ +void resetTest(void); +void resetTest(void) +{ + tearDown(); + CMock_Verify(); + CMock_Destroy(); + CMock_Init(); + setUp(); +} +void verifyTest(void); +void verifyTest(void) +{ + CMock_Verify(); +} + +/*=======Test Runner Used To Run Each Test=====*/ +static void run_test(UnityTestFunction func, const char* name, UNITY_LINE_TYPE line_num) +{ + Unity.CurrentTestName = name; + Unity.CurrentTestLineNumber = line_num; +#ifdef UNITY_USE_COMMAND_LINE_ARGS + if (!UnityTestMatches()) + return; +#endif + Unity.NumberOfTests++; + UNITY_CLR_DETAILS(); + UNITY_EXEC_TIME_START(); + CMock_Init(); + if (TEST_PROTECT()) + { + setUp(); + func(); + } + if (TEST_PROTECT()) + { + tearDown(); + CMock_Verify(); + } + CMock_Destroy(); + UNITY_EXEC_TIME_STOP(); + UnityConcludeTest(); +} + +/*=======MAIN=====*/ +int main(void) +{ + UnityBegin("test_minirechner.c"); + run_test(test_minitaschenrechner_3_plus_4, "test_minitaschenrechner_3_plus_4", 16); + run_test(test_minitaschenrechner_float_plus_float, "test_minitaschenrechner_float_plus_float", 22); + run_test(test_minitaschenrechner_minus1_plus_minus3, "test_minitaschenrechner_minus1_plus_minus3", 28); + run_test(test_minitaschenrechner_0_plus_2, "test_minitaschenrechner_0_plus_2", 34); + run_test(test_minitaschenrechner_5_minus_2, "test_minitaschenrechner_5_minus_2", 41); + run_test(test_minitaschenrechner_float_minus_float, "test_minitaschenrechner_float_minus_float", 47); + run_test(test_minitaschenrechner_minus7_minus_minus3, "test_minitaschenrechner_minus7_minus_minus3", 53); + run_test(test_minitaschenrechner_4_minus_0, "test_minitaschenrechner_4_minus_0", 59); + run_test(test_minitaschenrechner_8_mal_3, "test_minitaschenrechner_8_mal_3", 66); + run_test(test_minitaschenrechner_minus3_mal_minus4, "test_minitaschenrechner_minus3_mal_minus4", 72); + run_test(test_minitaschenrechner_0_mal_5, "test_minitaschenrechner_0_mal_5", 78); + run_test(test_minitaschenrechner_9_durch_3, "test_minitaschenrechner_9_durch_3", 85); + run_test(test_minitaschenrechner_minus6_durch_minus2, "test_minitaschenrechner_minus6_durch_minus2", 91); + run_test(test_minitaschenrechner_0_durch_5, "test_minitaschenrechner_0_durch_5", 97); + run_test(test_minitaschenrechner_14_rest_5, "test_minitaschenrechner_14_rest_5", 104); + run_test(test_minitaschenrechner_1_rest_7, "test_minitaschenrechner_1_rest_7", 110); + run_test(test_minitaschenrechner_120_groesster_gemeinsammer_teiler_30, "test_minitaschenrechner_120_groesster_gemeinsammer_teiler_30", 117); + run_test(test_minitaschenrechner_120_kleinstes_gemeinsammes_vielfaches_50, "test_minitaschenrechner_120_kleinstes_gemeinsammes_vielfaches_50", 124); + + return UnityEnd(); +} diff --git a/build/test/runners/test_zahlenraten_runner.c b/build/test/runners/test_zahlenraten_runner.c new file mode 100644 index 0000000..ae2a644 --- /dev/null +++ b/build/test/runners/test_zahlenraten_runner.c @@ -0,0 +1,81 @@ +/* AUTOGENERATED FILE. DO NOT EDIT. */ + +/*=======Automagically Detected Files To Include=====*/ +#include "unity.h" + +int GlobalExpectCount; +int GlobalVerifyOrder; +char* GlobalOrderError; + +/*=======External Functions This Runner Calls=====*/ +extern void setUp(void); +extern void tearDown(void); +extern void test_zahlenraten_gib_zufallszahl(void); + + +/*=======Mock Management=====*/ +static void CMock_Init(void) +{ + GlobalExpectCount = 0; + GlobalVerifyOrder = 0; + GlobalOrderError = NULL; +} +static void CMock_Verify(void) +{ +} +static void CMock_Destroy(void) +{ +} + +/*=======Test Reset Options=====*/ +void resetTest(void); +void resetTest(void) +{ + tearDown(); + CMock_Verify(); + CMock_Destroy(); + CMock_Init(); + setUp(); +} +void verifyTest(void); +void verifyTest(void) +{ + CMock_Verify(); +} + +/*=======Test Runner Used To Run Each Test=====*/ +static void run_test(UnityTestFunction func, const char* name, UNITY_LINE_TYPE line_num) +{ + Unity.CurrentTestName = name; + Unity.CurrentTestLineNumber = line_num; +#ifdef UNITY_USE_COMMAND_LINE_ARGS + if (!UnityTestMatches()) + return; +#endif + Unity.NumberOfTests++; + UNITY_CLR_DETAILS(); + UNITY_EXEC_TIME_START(); + CMock_Init(); + if (TEST_PROTECT()) + { + setUp(); + func(); + } + if (TEST_PROTECT()) + { + tearDown(); + CMock_Verify(); + } + CMock_Destroy(); + UNITY_EXEC_TIME_STOP(); + UnityConcludeTest(); +} + +/*=======MAIN=====*/ +int main(void) +{ + UnityBegin("test_zahlenraten.c"); + run_test(test_zahlenraten_gib_zufallszahl, "test_zahlenraten_gib_zufallszahl", 15); + + return UnityEnd(); +} diff --git a/src/SchereSteinPapier.c b/src/SchereSteinPapier.c new file mode 100644 index 0000000..7b58b07 --- /dev/null +++ b/src/SchereSteinPapier.c @@ -0,0 +1 @@ +#include "SchereSteinPapier.h" diff --git a/src/SchereSteinPapier.h b/src/SchereSteinPapier.h new file mode 100644 index 0000000..9584c8e --- /dev/null +++ b/src/SchereSteinPapier.h @@ -0,0 +1,5 @@ +#ifndef SCHERESTEINPAPIER_H +#define SCHERESTEINPAPIER_H + + +#endif // SCHERESTEINPAPIER_H diff --git a/test/test_SchereSteinPapier.c b/test/test_SchereSteinPapier.c new file mode 100644 index 0000000..931e98e --- /dev/null +++ b/test/test_SchereSteinPapier.c @@ -0,0 +1,20 @@ +#ifdef TEST + +#include "unity.h" + +#include "SchereSteinPapier.h" + +void setUp(void) +{ +} + +void tearDown(void) +{ +} + +void test_SchereSteinPapier_NeedToImplement(void) +{ + TEST_IGNORE_MESSAGE("Need to Implement SchereSteinPapier"); +} + +#endif // TEST