ceedling 0.20.3 → 0.21.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (407) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile +3 -0
  3. data/Gemfile.lock +1 -0
  4. data/Rakefile +1 -0
  5. data/bin/ceedling +79 -26
  6. data/lib/ceedling/configurator_plugins.rb +0 -18
  7. data/lib/ceedling/rules_cmock.rake +1 -1
  8. data/lib/ceedling/tasks_base.rake +5 -1
  9. data/lib/ceedling/tasks_tests.rake +12 -9
  10. data/lib/ceedling/version.rb +1 -1
  11. data/lib/ceedling/version.rb.erb +1 -1
  12. data/plugins/fake_function_framework/README.md +250 -0
  13. data/plugins/fake_function_framework/Rakefile +19 -0
  14. data/plugins/fake_function_framework/examples/fff_example/project.yml +71 -0
  15. data/plugins/fake_function_framework/examples/fff_example/rakefile.rb +7 -0
  16. data/plugins/fake_function_framework/examples/fff_example/src/bar.c +1 -0
  17. data/plugins/fake_function_framework/examples/fff_example/src/bar.h +13 -0
  18. data/plugins/fake_function_framework/examples/fff_example/src/custom_types.h +6 -0
  19. data/plugins/fake_function_framework/examples/fff_example/src/display.c +7 -0
  20. data/plugins/fake_function_framework/examples/fff_example/src/display.h +16 -0
  21. data/plugins/fake_function_framework/examples/fff_example/src/event_processor.c +92 -0
  22. data/plugins/fake_function_framework/examples/fff_example/src/event_processor.h +11 -0
  23. data/plugins/fake_function_framework/examples/fff_example/src/foo.c +16 -0
  24. data/plugins/fake_function_framework/examples/fff_example/src/foo.h +8 -0
  25. data/plugins/fake_function_framework/examples/fff_example/src/subfolder/zzz.c +1 -0
  26. data/plugins/fake_function_framework/examples/fff_example/src/subfolder/zzz.h +6 -0
  27. data/plugins/fake_function_framework/examples/fff_example/test/test_event_processor.c +155 -0
  28. data/plugins/fake_function_framework/examples/fff_example/test/test_foo.c +47 -0
  29. data/plugins/fake_function_framework/lib/fake_function_framework.rb +87 -0
  30. data/plugins/fake_function_framework/lib/fff_mock_generator.rb +159 -0
  31. data/plugins/fake_function_framework/spec/fff_mock_generator_spec.rb +464 -0
  32. data/plugins/fake_function_framework/spec/spec_helper.rb +96 -0
  33. data/plugins/fake_function_framework/src/fff_unity_helper.h +33 -0
  34. data/plugins/fake_function_framework/vendor/fff/LICENSE +25 -0
  35. data/plugins/fake_function_framework/vendor/fff/Makefile +10 -0
  36. data/plugins/fake_function_framework/vendor/fff/README.md +454 -0
  37. data/plugins/fake_function_framework/vendor/fff/buildandtest +15 -0
  38. data/plugins/fake_function_framework/vendor/fff/examples/Makefile +7 -0
  39. data/plugins/fake_function_framework/vendor/fff/examples/driver_testing/Makefile +64 -0
  40. data/plugins/fake_function_framework/vendor/fff/examples/driver_testing/driver.c +24 -0
  41. data/plugins/fake_function_framework/vendor/fff/examples/driver_testing/driver.h +11 -0
  42. data/plugins/fake_function_framework/vendor/fff/examples/driver_testing/driver.test.cpp +50 -0
  43. data/plugins/fake_function_framework/vendor/fff/examples/driver_testing/driver.test.fff.cpp +62 -0
  44. data/plugins/fake_function_framework/vendor/fff/examples/driver_testing/hardware_abstraction.h +15 -0
  45. data/plugins/fake_function_framework/vendor/fff/examples/driver_testing/registers.h +13 -0
  46. data/plugins/fake_function_framework/vendor/fff/examples/embedded_ui/DISPLAY.h +17 -0
  47. data/plugins/fake_function_framework/vendor/fff/examples/embedded_ui/Kata.txt +25 -0
  48. data/plugins/fake_function_framework/vendor/fff/examples/embedded_ui/Makefile +67 -0
  49. data/plugins/fake_function_framework/vendor/fff/examples/embedded_ui/SYSTEM.h +21 -0
  50. data/plugins/fake_function_framework/vendor/fff/examples/embedded_ui/UI.c +48 -0
  51. data/plugins/fake_function_framework/vendor/fff/examples/embedded_ui/UI.h +12 -0
  52. data/plugins/fake_function_framework/vendor/fff/examples/embedded_ui/UI_test_ansic.c +183 -0
  53. data/plugins/fake_function_framework/vendor/fff/examples/embedded_ui/UI_test_cpp.cpp +136 -0
  54. data/plugins/fake_function_framework/vendor/fff/examples/embedded_ui/test_suite_template.c +34 -0
  55. data/plugins/fake_function_framework/vendor/fff/fakegen.rb +420 -0
  56. data/plugins/fake_function_framework/vendor/fff/fff.h +5112 -0
  57. data/plugins/fake_function_framework/vendor/fff/gtest/Makefile +22 -0
  58. data/plugins/fake_function_framework/vendor/fff/gtest/gtest-all.cc +9118 -0
  59. data/plugins/fake_function_framework/vendor/fff/gtest/gtest-main.cc +6 -0
  60. data/plugins/fake_function_framework/vendor/fff/gtest/gtest.h +19537 -0
  61. data/plugins/fake_function_framework/vendor/fff/test/Makefile +81 -0
  62. data/plugins/fake_function_framework/vendor/fff/test/c_test_framework.h +15 -0
  63. data/plugins/fake_function_framework/vendor/fff/test/fff_test_c.c +108 -0
  64. data/plugins/fake_function_framework/vendor/fff/test/fff_test_cpp.cpp +45 -0
  65. data/plugins/fake_function_framework/vendor/fff/test/fff_test_global_c.c +76 -0
  66. data/plugins/fake_function_framework/vendor/fff/test/fff_test_global_cpp.cpp +23 -0
  67. data/plugins/fake_function_framework/vendor/fff/test/global_fakes.c +13 -0
  68. data/plugins/fake_function_framework/vendor/fff/test/global_fakes.h +37 -0
  69. data/plugins/fake_function_framework/vendor/fff/test/test_cases.include +276 -0
  70. data/plugins/gcov/README.md +9 -0
  71. data/plugins/gcov/{template.erb → assets/template.erb} +1 -1
  72. data/plugins/gcov/{defaults.yml → config/defaults.yml} +10 -1
  73. data/plugins/gcov/gcov.rake +20 -8
  74. data/plugins/gcov/{gcov.rb → lib/gcov.rb} +13 -24
  75. data/plugins/module_generator/module_generator.rake +3 -3
  76. data/plugins/warnings_report/lib/warnings_report.rb +69 -0
  77. data/plugins/xml_tests_report/lib/xml_tests_report.rb +108 -0
  78. data/spec/spec_system_helper.rb +1 -1
  79. data/vendor/c_exception/lib/CException.h +1 -1
  80. data/vendor/c_exception/vendor/unity/auto/generate_module.rb +16 -16
  81. data/vendor/c_exception/vendor/unity/auto/generate_test_runner.rb +61 -21
  82. data/vendor/c_exception/vendor/unity/auto/stylize_as_junit.rb +5 -1
  83. data/vendor/c_exception/vendor/unity/auto/unity_to_junit.py +146 -0
  84. data/vendor/c_exception/vendor/unity/docs/UnityAssertionsCheatSheetSuitableforPrintingandPossiblyFraming.pdf +0 -0
  85. data/vendor/c_exception/vendor/unity/docs/UnityAssertionsReference.pdf +0 -0
  86. data/vendor/c_exception/vendor/unity/docs/UnityConfigurationGuide.pdf +0 -0
  87. data/vendor/c_exception/vendor/unity/docs/UnityGettingStartedGuide.pdf +0 -0
  88. data/vendor/c_exception/vendor/unity/docs/UnityHelperScriptsGuide.pdf +0 -0
  89. data/vendor/c_exception/vendor/unity/examples/example_1/makefile +1 -1
  90. data/vendor/c_exception/vendor/unity/examples/example_1/src/ProductionCode.c +7 -7
  91. data/vendor/c_exception/vendor/unity/examples/example_1/src/ProductionCode2.c +2 -2
  92. data/vendor/c_exception/vendor/unity/examples/example_1/test/TestProductionCode.c +14 -14
  93. data/vendor/c_exception/vendor/unity/examples/example_1/test/TestProductionCode2.c +2 -2
  94. data/vendor/c_exception/vendor/unity/examples/example_1/test/test_runners/TestProductionCode2_Runner.c +5 -5
  95. data/vendor/c_exception/vendor/unity/examples/example_1/test/test_runners/TestProductionCode_Runner.c +5 -5
  96. data/vendor/c_exception/vendor/unity/examples/unity_config.h +257 -0
  97. data/vendor/c_exception/vendor/unity/extras/fixture/src/unity_fixture.c +9 -8
  98. data/vendor/c_exception/vendor/unity/extras/fixture/src/unity_fixture_internals.h +1 -0
  99. data/vendor/c_exception/vendor/unity/extras/fixture/test/Makefile +28 -8
  100. data/vendor/c_exception/vendor/unity/extras/fixture/test/unity_fixture_Test.c +57 -17
  101. data/vendor/c_exception/vendor/unity/extras/fixture/test/unity_fixture_TestRunner.c +3 -0
  102. data/vendor/c_exception/vendor/unity/extras/fixture/test/unity_output_Spy.c +2 -3
  103. data/vendor/c_exception/vendor/unity/extras/fixture/test/unity_output_Spy.h +1 -1
  104. data/vendor/c_exception/vendor/unity/release/version.info +1 -1
  105. data/vendor/c_exception/vendor/unity/src/unity.c +336 -191
  106. data/vendor/c_exception/vendor/unity/src/unity.h +73 -69
  107. data/vendor/c_exception/vendor/unity/src/unity_internals.h +119 -90
  108. data/vendor/c_exception/vendor/unity/test/Makefile +51 -0
  109. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_cmd.c +5 -5
  110. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_def.c +5 -5
  111. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_head1.c +5 -5
  112. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_cmd.c +6 -6
  113. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_def.c +6 -6
  114. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_head1.c +6 -6
  115. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_new1.c +6 -6
  116. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_new2.c +8 -8
  117. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_param.c +6 -6
  118. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_run1.c +6 -6
  119. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_run2.c +8 -8
  120. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_yaml.c +7 -7
  121. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_new1.c +5 -5
  122. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_new2.c +7 -7
  123. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_param.c +5 -5
  124. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_run1.c +5 -5
  125. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_run2.c +7 -7
  126. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_yaml.c +6 -6
  127. data/vendor/c_exception/vendor/unity/test/rakefile +5 -0
  128. data/vendor/c_exception/vendor/unity/test/rakefile_helper.rb +9 -7
  129. data/vendor/c_exception/vendor/unity/test/targets/clang_file.yml +1 -0
  130. data/vendor/c_exception/vendor/unity/test/targets/clang_strict.yml +3 -0
  131. data/vendor/c_exception/vendor/unity/test/targets/gcc_32.yml +1 -0
  132. data/vendor/c_exception/vendor/unity/test/targets/gcc_64.yml +1 -0
  133. data/vendor/c_exception/vendor/unity/test/targets/gcc_auto_limits.yml +1 -0
  134. data/vendor/c_exception/vendor/unity/test/targets/gcc_auto_sizeof.yml +1 -0
  135. data/vendor/c_exception/vendor/unity/test/targets/gcc_auto_stdint.yml +1 -0
  136. data/vendor/c_exception/vendor/unity/test/targets/gcc_manual_math.yml +1 -0
  137. data/vendor/c_exception/vendor/unity/test/targets/iar_arm_v4.yml +1 -0
  138. data/vendor/c_exception/vendor/unity/test/targets/iar_arm_v5.yml +1 -0
  139. data/vendor/c_exception/vendor/unity/test/targets/iar_arm_v5_3.yml +1 -0
  140. data/vendor/c_exception/vendor/unity/test/targets/iar_armcortex_LM3S9B92_v5_4.yml +1 -0
  141. data/vendor/c_exception/vendor/unity/test/targets/iar_cortexm3_v5.yml +1 -0
  142. data/vendor/c_exception/vendor/unity/test/targets/iar_msp430.yml +1 -0
  143. data/vendor/c_exception/vendor/unity/test/targets/iar_sh2a_v6.yml +1 -0
  144. data/vendor/c_exception/vendor/unity/test/testdata/CException.h +11 -0
  145. data/vendor/c_exception/vendor/unity/test/testdata/Defs.h +8 -0
  146. data/vendor/c_exception/vendor/unity/test/testdata/cmock.h +14 -0
  147. data/vendor/c_exception/vendor/unity/test/testdata/mockMock.h +13 -0
  148. data/vendor/c_exception/vendor/unity/test/testdata/testRunnerGenerator.c +183 -0
  149. data/vendor/c_exception/vendor/unity/test/testdata/testRunnerGeneratorSmall.c +65 -0
  150. data/vendor/c_exception/vendor/unity/test/testdata/testRunnerGeneratorWithMocks.c +192 -0
  151. data/vendor/c_exception/vendor/unity/test/tests/test_generate_test_runner.rb +1221 -71
  152. data/vendor/c_exception/vendor/unity/test/tests/testparameterized.c +1 -1
  153. data/vendor/c_exception/vendor/unity/test/tests/testunity.c +127 -5
  154. data/vendor/cmock/docs/CMock_Summary.md +1 -1
  155. data/vendor/cmock/lib/cmock_generator.rb +7 -2
  156. data/vendor/cmock/lib/cmock_header_parser.rb +29 -9
  157. data/vendor/cmock/scripts/create_mock.rb +1 -1
  158. data/vendor/cmock/test/system/test_compilation/const.h +15 -0
  159. data/vendor/cmock/test/unit/cmock_generator_main_test.rb +4 -4
  160. data/vendor/cmock/test/unit/cmock_header_parser_test.rb +136 -73
  161. data/vendor/cmock/vendor/c_exception/lib/CException.h +1 -1
  162. data/vendor/cmock/vendor/c_exception/vendor/unity/auto/generate_module.rb +16 -16
  163. data/vendor/cmock/vendor/c_exception/vendor/unity/auto/generate_test_runner.rb +61 -21
  164. data/vendor/cmock/vendor/c_exception/vendor/unity/auto/stylize_as_junit.rb +5 -1
  165. data/vendor/cmock/vendor/c_exception/vendor/unity/auto/unity_to_junit.py +146 -0
  166. data/vendor/cmock/vendor/c_exception/vendor/unity/docs/UnityAssertionsCheatSheetSuitableforPrintingandPossiblyFraming.pdf +0 -0
  167. data/vendor/cmock/vendor/c_exception/vendor/unity/docs/UnityAssertionsReference.pdf +0 -0
  168. data/vendor/cmock/vendor/c_exception/vendor/unity/docs/UnityConfigurationGuide.pdf +0 -0
  169. data/vendor/cmock/vendor/c_exception/vendor/unity/docs/UnityGettingStartedGuide.pdf +0 -0
  170. data/vendor/cmock/vendor/c_exception/vendor/unity/docs/UnityHelperScriptsGuide.pdf +0 -0
  171. data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_1/makefile +1 -1
  172. data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_1/src/ProductionCode.c +7 -7
  173. data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_1/src/ProductionCode2.c +2 -2
  174. data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_1/test/TestProductionCode.c +14 -14
  175. data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_1/test/TestProductionCode2.c +2 -2
  176. data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_1/test/test_runners/TestProductionCode2_Runner.c +5 -5
  177. data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_1/test/test_runners/TestProductionCode_Runner.c +5 -5
  178. data/vendor/cmock/vendor/c_exception/vendor/unity/examples/unity_config.h +257 -0
  179. data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/src/unity_fixture.c +9 -8
  180. data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/src/unity_fixture_internals.h +1 -0
  181. data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/test/Makefile +28 -8
  182. data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/test/unity_fixture_Test.c +57 -17
  183. data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/test/unity_fixture_TestRunner.c +3 -0
  184. data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/test/unity_output_Spy.c +2 -3
  185. data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/test/unity_output_Spy.h +1 -1
  186. data/vendor/cmock/vendor/c_exception/vendor/unity/release/version.info +1 -1
  187. data/vendor/cmock/vendor/c_exception/vendor/unity/src/unity.c +336 -191
  188. data/vendor/cmock/vendor/c_exception/vendor/unity/src/unity.h +73 -69
  189. data/vendor/cmock/vendor/c_exception/vendor/unity/src/unity_internals.h +119 -90
  190. data/vendor/cmock/vendor/c_exception/vendor/unity/test/Makefile +51 -0
  191. data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_cmd.c +5 -5
  192. data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_def.c +5 -5
  193. data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_head1.c +5 -5
  194. data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_cmd.c +6 -6
  195. data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_def.c +6 -6
  196. data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_head1.c +6 -6
  197. data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_new1.c +6 -6
  198. data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_new2.c +8 -8
  199. data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_param.c +6 -6
  200. data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_run1.c +6 -6
  201. data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_run2.c +8 -8
  202. data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_yaml.c +7 -7
  203. data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_new1.c +5 -5
  204. data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_new2.c +7 -7
  205. data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_param.c +5 -5
  206. data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_run1.c +5 -5
  207. data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_run2.c +7 -7
  208. data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_yaml.c +6 -6
  209. data/vendor/cmock/vendor/c_exception/vendor/unity/test/rakefile +5 -0
  210. data/vendor/cmock/vendor/c_exception/vendor/unity/test/rakefile_helper.rb +9 -7
  211. data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/clang_file.yml +1 -0
  212. data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/clang_strict.yml +3 -0
  213. data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/gcc_32.yml +1 -0
  214. data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/gcc_64.yml +1 -0
  215. data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/gcc_auto_limits.yml +1 -0
  216. data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/gcc_auto_sizeof.yml +1 -0
  217. data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/gcc_auto_stdint.yml +1 -0
  218. data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/gcc_manual_math.yml +1 -0
  219. data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/iar_arm_v4.yml +1 -0
  220. data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/iar_arm_v5.yml +1 -0
  221. data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/iar_arm_v5_3.yml +1 -0
  222. data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/iar_armcortex_LM3S9B92_v5_4.yml +1 -0
  223. data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/iar_cortexm3_v5.yml +1 -0
  224. data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/iar_msp430.yml +1 -0
  225. data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/iar_sh2a_v6.yml +1 -0
  226. data/vendor/cmock/vendor/c_exception/vendor/unity/test/testdata/CException.h +11 -0
  227. data/vendor/cmock/vendor/c_exception/vendor/unity/test/testdata/Defs.h +8 -0
  228. data/vendor/cmock/vendor/c_exception/vendor/unity/test/testdata/cmock.h +14 -0
  229. data/vendor/cmock/vendor/c_exception/vendor/unity/test/testdata/mockMock.h +13 -0
  230. data/vendor/cmock/vendor/c_exception/vendor/unity/test/testdata/testRunnerGenerator.c +183 -0
  231. data/vendor/cmock/vendor/c_exception/vendor/unity/test/testdata/testRunnerGeneratorSmall.c +65 -0
  232. data/vendor/cmock/vendor/c_exception/vendor/unity/test/testdata/testRunnerGeneratorWithMocks.c +192 -0
  233. data/vendor/cmock/vendor/c_exception/vendor/unity/test/tests/test_generate_test_runner.rb +1221 -71
  234. data/vendor/cmock/vendor/c_exception/vendor/unity/test/tests/testparameterized.c +1 -1
  235. data/vendor/cmock/vendor/c_exception/vendor/unity/test/tests/testunity.c +127 -5
  236. data/vendor/cmock/vendor/unity/auto/generate_module.rb +16 -16
  237. data/vendor/cmock/vendor/unity/auto/generate_test_runner.rb +61 -21
  238. data/vendor/cmock/vendor/unity/auto/stylize_as_junit.rb +5 -1
  239. data/vendor/cmock/vendor/unity/auto/unity_to_junit.py +146 -0
  240. data/vendor/cmock/vendor/unity/docs/UnityAssertionsCheatSheetSuitableforPrintingandPossiblyFraming.pdf +0 -0
  241. data/vendor/cmock/vendor/unity/docs/UnityAssertionsReference.pdf +0 -0
  242. data/vendor/cmock/vendor/unity/docs/UnityConfigurationGuide.pdf +0 -0
  243. data/vendor/cmock/vendor/unity/docs/UnityGettingStartedGuide.pdf +0 -0
  244. data/vendor/cmock/vendor/unity/docs/UnityHelperScriptsGuide.pdf +0 -0
  245. data/vendor/cmock/vendor/unity/examples/example_1/makefile +1 -1
  246. data/vendor/cmock/vendor/unity/examples/example_1/src/ProductionCode.c +7 -7
  247. data/vendor/cmock/vendor/unity/examples/example_1/src/ProductionCode2.c +2 -2
  248. data/vendor/cmock/vendor/unity/examples/example_1/test/TestProductionCode.c +14 -14
  249. data/vendor/cmock/vendor/unity/examples/example_1/test/TestProductionCode2.c +2 -2
  250. data/vendor/cmock/vendor/unity/examples/example_1/test/test_runners/TestProductionCode2_Runner.c +5 -5
  251. data/vendor/cmock/vendor/unity/examples/example_1/test/test_runners/TestProductionCode_Runner.c +5 -5
  252. data/vendor/cmock/vendor/unity/examples/unity_config.h +257 -0
  253. data/vendor/cmock/vendor/unity/extras/fixture/src/unity_fixture.c +3 -0
  254. data/vendor/cmock/vendor/unity/extras/fixture/test/unity_fixture_Test.c +5 -2
  255. data/vendor/cmock/vendor/unity/extras/fixture/test/unity_output_Spy.c +1 -2
  256. data/vendor/cmock/vendor/unity/extras/fixture/test/unity_output_Spy.h +1 -1
  257. data/vendor/cmock/vendor/unity/src/unity.c +329 -186
  258. data/vendor/cmock/vendor/unity/src/unity.h +73 -69
  259. data/vendor/cmock/vendor/unity/src/unity_internals.h +119 -94
  260. data/vendor/cmock/vendor/unity/test/Makefile +4 -5
  261. data/vendor/cmock/vendor/unity/test/expectdata/testsample_cmd.c +5 -5
  262. data/vendor/cmock/vendor/unity/test/expectdata/testsample_def.c +5 -5
  263. data/vendor/cmock/vendor/unity/test/expectdata/testsample_head1.c +5 -5
  264. data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_cmd.c +6 -6
  265. data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_def.c +6 -6
  266. data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_head1.c +6 -6
  267. data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_new1.c +6 -6
  268. data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_new2.c +8 -8
  269. data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_param.c +6 -6
  270. data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_run1.c +6 -6
  271. data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_run2.c +8 -8
  272. data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_yaml.c +7 -7
  273. data/vendor/cmock/vendor/unity/test/expectdata/testsample_new1.c +5 -5
  274. data/vendor/cmock/vendor/unity/test/expectdata/testsample_new2.c +7 -7
  275. data/vendor/cmock/vendor/unity/test/expectdata/testsample_param.c +5 -5
  276. data/vendor/cmock/vendor/unity/test/expectdata/testsample_run1.c +5 -5
  277. data/vendor/cmock/vendor/unity/test/expectdata/testsample_run2.c +7 -7
  278. data/vendor/cmock/vendor/unity/test/expectdata/testsample_yaml.c +6 -6
  279. data/vendor/cmock/vendor/unity/test/rakefile +5 -0
  280. data/vendor/cmock/vendor/unity/test/rakefile_helper.rb +9 -7
  281. data/vendor/cmock/vendor/unity/test/targets/clang_file.yml +1 -0
  282. data/vendor/cmock/vendor/unity/test/targets/clang_strict.yml +3 -0
  283. data/vendor/cmock/vendor/unity/test/targets/gcc_32.yml +1 -0
  284. data/vendor/cmock/vendor/unity/test/targets/gcc_64.yml +1 -0
  285. data/vendor/cmock/vendor/unity/test/targets/gcc_auto_limits.yml +1 -0
  286. data/vendor/cmock/vendor/unity/test/targets/gcc_auto_sizeof.yml +1 -0
  287. data/vendor/cmock/vendor/unity/test/targets/gcc_auto_stdint.yml +1 -0
  288. data/vendor/cmock/vendor/unity/test/targets/gcc_manual_math.yml +1 -0
  289. data/vendor/cmock/vendor/unity/test/targets/iar_arm_v4.yml +1 -0
  290. data/vendor/cmock/vendor/unity/test/targets/iar_arm_v5.yml +1 -0
  291. data/vendor/cmock/vendor/unity/test/targets/iar_arm_v5_3.yml +1 -0
  292. data/vendor/cmock/vendor/unity/test/targets/iar_armcortex_LM3S9B92_v5_4.yml +1 -0
  293. data/vendor/cmock/vendor/unity/test/targets/iar_cortexm3_v5.yml +1 -0
  294. data/vendor/cmock/vendor/unity/test/targets/iar_msp430.yml +1 -0
  295. data/vendor/cmock/vendor/unity/test/targets/iar_sh2a_v6.yml +1 -0
  296. data/vendor/cmock/vendor/unity/test/testdata/CException.h +11 -0
  297. data/vendor/cmock/vendor/unity/test/testdata/Defs.h +8 -0
  298. data/vendor/cmock/vendor/unity/test/testdata/cmock.h +14 -0
  299. data/vendor/cmock/vendor/unity/test/testdata/mockMock.h +13 -0
  300. data/vendor/cmock/vendor/unity/test/testdata/testRunnerGenerator.c +183 -0
  301. data/vendor/cmock/vendor/unity/test/testdata/testRunnerGeneratorSmall.c +65 -0
  302. data/vendor/cmock/vendor/unity/test/testdata/testRunnerGeneratorWithMocks.c +192 -0
  303. data/vendor/cmock/vendor/unity/test/tests/test_generate_test_runner.rb +1221 -71
  304. data/vendor/cmock/vendor/unity/test/tests/testparameterized.c +1 -1
  305. data/vendor/cmock/vendor/unity/test/tests/testunity.c +104 -7
  306. data/vendor/deep_merge/README +94 -94
  307. data/vendor/deep_merge/Rakefile +28 -28
  308. data/vendor/deep_merge/lib/deep_merge.rb +211 -211
  309. data/vendor/deep_merge/test/test_deep_merge.rb +553 -553
  310. data/vendor/unity/auto/generate_module.rb +16 -16
  311. data/vendor/unity/auto/generate_test_runner.rb +61 -21
  312. data/vendor/unity/auto/stylize_as_junit.rb +5 -1
  313. data/vendor/unity/auto/unity_to_junit.py +146 -0
  314. data/vendor/unity/docs/UnityAssertionsCheatSheetSuitableforPrintingandPossiblyFraming.pdf +0 -0
  315. data/vendor/unity/docs/UnityAssertionsReference.pdf +0 -0
  316. data/vendor/unity/docs/UnityConfigurationGuide.pdf +0 -0
  317. data/vendor/unity/docs/UnityGettingStartedGuide.pdf +0 -0
  318. data/vendor/unity/docs/UnityHelperScriptsGuide.pdf +0 -0
  319. data/vendor/unity/examples/example_1/makefile +1 -1
  320. data/vendor/unity/examples/example_1/src/ProductionCode.c +7 -7
  321. data/vendor/unity/examples/example_1/src/ProductionCode2.c +2 -2
  322. data/vendor/unity/examples/example_1/test/TestProductionCode.c +14 -14
  323. data/vendor/unity/examples/example_1/test/TestProductionCode2.c +2 -2
  324. data/vendor/unity/examples/example_1/test/test_runners/TestProductionCode2_Runner.c +5 -5
  325. data/vendor/unity/examples/example_1/test/test_runners/TestProductionCode_Runner.c +5 -5
  326. data/vendor/unity/examples/unity_config.h +257 -0
  327. data/vendor/unity/extras/fixture/src/unity_fixture.c +3 -0
  328. data/vendor/unity/extras/fixture/test/unity_fixture_Test.c +5 -2
  329. data/vendor/unity/extras/fixture/test/unity_output_Spy.c +1 -2
  330. data/vendor/unity/extras/fixture/test/unity_output_Spy.h +1 -1
  331. data/vendor/unity/src/unity.c +329 -186
  332. data/vendor/unity/src/unity.h +73 -69
  333. data/vendor/unity/src/unity_internals.h +119 -94
  334. data/vendor/unity/test/Makefile +4 -5
  335. data/vendor/unity/test/expectdata/testsample_cmd.c +5 -5
  336. data/vendor/unity/test/expectdata/testsample_def.c +5 -5
  337. data/vendor/unity/test/expectdata/testsample_head1.c +5 -5
  338. data/vendor/unity/test/expectdata/testsample_mock_cmd.c +6 -6
  339. data/vendor/unity/test/expectdata/testsample_mock_def.c +6 -6
  340. data/vendor/unity/test/expectdata/testsample_mock_head1.c +6 -6
  341. data/vendor/unity/test/expectdata/testsample_mock_new1.c +6 -6
  342. data/vendor/unity/test/expectdata/testsample_mock_new2.c +8 -8
  343. data/vendor/unity/test/expectdata/testsample_mock_param.c +6 -6
  344. data/vendor/unity/test/expectdata/testsample_mock_run1.c +6 -6
  345. data/vendor/unity/test/expectdata/testsample_mock_run2.c +8 -8
  346. data/vendor/unity/test/expectdata/testsample_mock_yaml.c +7 -7
  347. data/vendor/unity/test/expectdata/testsample_new1.c +5 -5
  348. data/vendor/unity/test/expectdata/testsample_new2.c +7 -7
  349. data/vendor/unity/test/expectdata/testsample_param.c +5 -5
  350. data/vendor/unity/test/expectdata/testsample_run1.c +5 -5
  351. data/vendor/unity/test/expectdata/testsample_run2.c +7 -7
  352. data/vendor/unity/test/expectdata/testsample_yaml.c +6 -6
  353. data/vendor/unity/test/rakefile +5 -0
  354. data/vendor/unity/test/rakefile_helper.rb +9 -7
  355. data/vendor/unity/test/targets/clang_file.yml +1 -0
  356. data/vendor/unity/test/targets/clang_strict.yml +3 -0
  357. data/vendor/unity/test/targets/gcc_32.yml +1 -0
  358. data/vendor/unity/test/targets/gcc_64.yml +1 -0
  359. data/vendor/unity/test/targets/gcc_auto_limits.yml +1 -0
  360. data/vendor/unity/test/targets/gcc_auto_sizeof.yml +1 -0
  361. data/vendor/unity/test/targets/gcc_auto_stdint.yml +1 -0
  362. data/vendor/unity/test/targets/gcc_manual_math.yml +1 -0
  363. data/vendor/unity/test/targets/iar_arm_v4.yml +1 -0
  364. data/vendor/unity/test/targets/iar_arm_v5.yml +1 -0
  365. data/vendor/unity/test/targets/iar_arm_v5_3.yml +1 -0
  366. data/vendor/unity/test/targets/iar_armcortex_LM3S9B92_v5_4.yml +1 -0
  367. data/vendor/unity/test/targets/iar_cortexm3_v5.yml +1 -0
  368. data/vendor/unity/test/targets/iar_msp430.yml +1 -0
  369. data/vendor/unity/test/targets/iar_sh2a_v6.yml +1 -0
  370. data/vendor/unity/test/testdata/CException.h +11 -0
  371. data/vendor/unity/test/testdata/Defs.h +8 -0
  372. data/vendor/unity/test/testdata/cmock.h +14 -0
  373. data/vendor/unity/test/testdata/mockMock.h +13 -0
  374. data/vendor/unity/test/testdata/testRunnerGenerator.c +183 -0
  375. data/vendor/unity/test/testdata/testRunnerGeneratorSmall.c +65 -0
  376. data/vendor/unity/test/testdata/testRunnerGeneratorWithMocks.c +192 -0
  377. data/vendor/unity/test/tests/test_generate_test_runner.rb +1221 -71
  378. data/vendor/unity/test/tests/testparameterized.c +1 -1
  379. data/vendor/unity/test/tests/testunity.c +104 -7
  380. metadata +124 -32
  381. data/plugins/gcov/readme.txt +0 -0
  382. data/plugins/warnings_report/warnings_report.rb +0 -71
  383. data/plugins/xml_tests_report/xml_tests_report.rb +0 -110
  384. data/vendor/c_exception/vendor/unity/docs/Unity Summary.odt +0 -0
  385. data/vendor/c_exception/vendor/unity/docs/Unity Summary.pdf +0 -0
  386. data/vendor/c_exception/vendor/unity/docs/Unity Summary.txt +0 -224
  387. data/vendor/c_exception/vendor/unity/test/testdata/mocksample.c +0 -51
  388. data/vendor/c_exception/vendor/unity/test/testdata/sample.yml +0 -9
  389. data/vendor/c_exception/vendor/unity/test/testdata/testsample.c +0 -68
  390. data/vendor/cmock/vendor/c_exception/vendor/unity/docs/Unity Summary.odt +0 -0
  391. data/vendor/cmock/vendor/c_exception/vendor/unity/docs/Unity Summary.pdf +0 -0
  392. data/vendor/cmock/vendor/c_exception/vendor/unity/docs/Unity Summary.txt +0 -224
  393. data/vendor/cmock/vendor/c_exception/vendor/unity/test/testdata/mocksample.c +0 -51
  394. data/vendor/cmock/vendor/c_exception/vendor/unity/test/testdata/sample.yml +0 -9
  395. data/vendor/cmock/vendor/c_exception/vendor/unity/test/testdata/testsample.c +0 -68
  396. data/vendor/cmock/vendor/unity/docs/Unity Summary.odt +0 -0
  397. data/vendor/cmock/vendor/unity/docs/Unity Summary.pdf +0 -0
  398. data/vendor/cmock/vendor/unity/docs/Unity Summary.txt +0 -224
  399. data/vendor/cmock/vendor/unity/test/testdata/mocksample.c +0 -51
  400. data/vendor/cmock/vendor/unity/test/testdata/sample.yml +0 -9
  401. data/vendor/cmock/vendor/unity/test/testdata/testsample.c +0 -68
  402. data/vendor/unity/docs/Unity Summary.odt +0 -0
  403. data/vendor/unity/docs/Unity Summary.pdf +0 -0
  404. data/vendor/unity/docs/Unity Summary.txt +0 -224
  405. data/vendor/unity/test/testdata/mocksample.c +0 -51
  406. data/vendor/unity/test/testdata/sample.yml +0 -9
  407. data/vendor/unity/test/testdata/testsample.c +0 -68
@@ -5,7 +5,7 @@ char* ThisFunctionHasNotBeenTested(int Poor, char* LittleFunction)
5
5
  {
6
6
  (void)Poor;
7
7
  (void)LittleFunction;
8
- //Since There Are No Tests Yet, This Function Could Be Empty For All We Know.
9
- // Which isn't terribly useful... but at least we put in a TEST_IGNORE so we won't forget
8
+ /* Since There Are No Tests Yet, This Function Could Be Empty For All We Know.
9
+ * Which isn't terribly useful... but at least we put in a TEST_IGNORE so we won't forget */
10
10
  return (char*)0;
11
11
  }
@@ -2,14 +2,14 @@
2
2
  #include "ProductionCode.h"
3
3
  #include "unity.h"
4
4
 
5
- //sometimes you may want to get at local data in a module.
6
- //for example: If you plan to pass by reference, this could be useful
7
- //however, it should often be avoided
5
+ /* sometimes you may want to get at local data in a module.
6
+ * for example: If you plan to pass by reference, this could be useful
7
+ * however, it should often be avoided */
8
8
  extern int Counter;
9
9
 
10
10
  void setUp(void)
11
11
  {
12
- //This is run before EACH TEST
12
+ /* This is run before EACH TEST */
13
13
  Counter = 0x5a5a;
14
14
  }
15
15
 
@@ -19,7 +19,7 @@ void tearDown(void)
19
19
 
20
20
  void test_FindFunction_WhichIsBroken_ShouldReturnZeroIfItemIsNotInList_WhichWorksEvenInOurBrokenCode(void)
21
21
  {
22
- //All of these should pass
22
+ /* All of these should pass */
23
23
  TEST_ASSERT_EQUAL(0, FindFunction_WhichIsBroken(78));
24
24
  TEST_ASSERT_EQUAL(0, FindFunction_WhichIsBroken(1));
25
25
  TEST_ASSERT_EQUAL(0, FindFunction_WhichIsBroken(33));
@@ -29,34 +29,34 @@ void test_FindFunction_WhichIsBroken_ShouldReturnZeroIfItemIsNotInList_WhichWork
29
29
 
30
30
  void test_FindFunction_WhichIsBroken_ShouldReturnTheIndexForItemsInList_WhichWillFailBecauseOurFunctionUnderTestIsBroken(void)
31
31
  {
32
- // You should see this line fail in your test summary
32
+ /* You should see this line fail in your test summary */
33
33
  TEST_ASSERT_EQUAL(1, FindFunction_WhichIsBroken(34));
34
34
 
35
- // Notice the rest of these didn't get a chance to run because the line above failed.
36
- // Unit tests abort each test function on the first sign of trouble.
37
- // Then NEXT test function runs as normal.
35
+ /* Notice the rest of these didn't get a chance to run because the line above failed.
36
+ * Unit tests abort each test function on the first sign of trouble.
37
+ * Then NEXT test function runs as normal. */
38
38
  TEST_ASSERT_EQUAL(8, FindFunction_WhichIsBroken(8888));
39
39
  }
40
40
 
41
41
  void test_FunctionWhichReturnsLocalVariable_ShouldReturnTheCurrentCounterValue(void)
42
42
  {
43
- //This should be true because setUp set this up for us before this test
43
+ /* This should be true because setUp set this up for us before this test */
44
44
  TEST_ASSERT_EQUAL_HEX(0x5a5a, FunctionWhichReturnsLocalVariable());
45
45
 
46
- //This should be true because we can still change our answer
46
+ /* This should be true because we can still change our answer */
47
47
  Counter = 0x1234;
48
48
  TEST_ASSERT_EQUAL_HEX(0x1234, FunctionWhichReturnsLocalVariable());
49
49
  }
50
50
 
51
51
  void test_FunctionWhichReturnsLocalVariable_ShouldReturnTheCurrentCounterValueAgain(void)
52
52
  {
53
- //This should be true again because setup was rerun before this test (and after we changed it to 0x1234)
53
+ /* This should be true again because setup was rerun before this test (and after we changed it to 0x1234) */
54
54
  TEST_ASSERT_EQUAL_HEX(0x5a5a, FunctionWhichReturnsLocalVariable());
55
55
  }
56
56
 
57
57
  void test_FunctionWhichReturnsLocalVariable_ShouldReturnCurrentCounter_ButFailsBecauseThisTestIsActuallyFlawed(void)
58
58
  {
59
- //Sometimes you get the test wrong. When that happens, you get a failure too... and a quick look should tell
60
- // you what actually happened...which in this case was a failure to setup the initial condition.
59
+ /* Sometimes you get the test wrong. When that happens, you get a failure too... and a quick look should tell
60
+ * you what actually happened...which in this case was a failure to setup the initial condition. */
61
61
  TEST_ASSERT_EQUAL_HEX(0x1234, FunctionWhichReturnsLocalVariable());
62
62
  }
@@ -4,8 +4,8 @@
4
4
 
5
5
  /* These should be ignored because they are commented out in various ways:
6
6
  #include "whatever.h"
7
+ #include "somethingelse.h"
7
8
  */
8
- //#include "somethingelse.h"
9
9
 
10
10
  void setUp(void)
11
11
  {
@@ -27,5 +27,5 @@ void test_AnotherIgnoredTest(void)
27
27
 
28
28
  void test_ThisFunctionHasNotBeenTested_NeedsToBeImplemented(void)
29
29
  {
30
- TEST_IGNORE(); //Like This
30
+ TEST_IGNORE(); /* Like This */
31
31
  }
@@ -1,6 +1,6 @@
1
1
  /* AUTOGENERATED FILE. DO NOT EDIT. */
2
2
 
3
- //=======Test Runner Used To Run Each Test Below=====
3
+ /*=======Test Runner Used To Run Each Test Below=====*/
4
4
  #define RUN_TEST(TestFunc, TestLineNum) \
5
5
  { \
6
6
  Unity.CurrentTestName = #TestFunc; \
@@ -18,13 +18,13 @@
18
18
  UnityConcludeTest(); \
19
19
  }
20
20
 
21
- //=======Automagically Detected Files To Include=====
21
+ /*=======Automagically Detected Files To Include=====*/
22
22
  #include "unity.h"
23
23
  #include <setjmp.h>
24
24
  #include <stdio.h>
25
25
  #include "ProductionCode2.h"
26
26
 
27
- //=======External Functions This Runner Calls=====
27
+ /*=======External Functions This Runner Calls=====*/
28
28
  extern void setUp(void);
29
29
  extern void tearDown(void);
30
30
  extern void test_IgnoredTest(void);
@@ -32,7 +32,7 @@ extern void test_AnotherIgnoredTest(void);
32
32
  extern void test_ThisFunctionHasNotBeenTested_NeedsToBeImplemented(void);
33
33
 
34
34
 
35
- //=======Test Reset Option=====
35
+ /*=======Test Reset Option=====*/
36
36
  void resetTest(void);
37
37
  void resetTest(void)
38
38
  {
@@ -41,7 +41,7 @@ void resetTest(void)
41
41
  }
42
42
 
43
43
 
44
- //=======MAIN=====
44
+ /*=======MAIN=====*/
45
45
  int main(void)
46
46
  {
47
47
  UnityBegin("test/TestProductionCode2.c");
@@ -1,6 +1,6 @@
1
1
  /* AUTOGENERATED FILE. DO NOT EDIT. */
2
2
 
3
- //=======Test Runner Used To Run Each Test Below=====
3
+ /*=======Test Runner Used To Run Each Test Below=====*/
4
4
  #define RUN_TEST(TestFunc, TestLineNum) \
5
5
  { \
6
6
  Unity.CurrentTestName = #TestFunc; \
@@ -18,13 +18,13 @@
18
18
  UnityConcludeTest(); \
19
19
  }
20
20
 
21
- //=======Automagically Detected Files To Include=====
21
+ /*=======Automagically Detected Files To Include=====*/
22
22
  #include "unity.h"
23
23
  #include <setjmp.h>
24
24
  #include <stdio.h>
25
25
  #include "ProductionCode.h"
26
26
 
27
- //=======External Functions This Runner Calls=====
27
+ /*=======External Functions This Runner Calls=====*/
28
28
  extern void setUp(void);
29
29
  extern void tearDown(void);
30
30
  extern void test_FindFunction_WhichIsBroken_ShouldReturnZeroIfItemIsNotInList_WhichWorksEvenInOurBrokenCode(void);
@@ -34,7 +34,7 @@ extern void test_FunctionWhichReturnsLocalVariable_ShouldReturnTheCurrentCounter
34
34
  extern void test_FunctionWhichReturnsLocalVariable_ShouldReturnCurrentCounter_ButFailsBecauseThisTestIsActuallyFlawed(void);
35
35
 
36
36
 
37
- //=======Test Reset Option=====
37
+ /*=======Test Reset Option=====*/
38
38
  void resetTest(void);
39
39
  void resetTest(void)
40
40
  {
@@ -43,7 +43,7 @@ void resetTest(void)
43
43
  }
44
44
 
45
45
 
46
- //=======MAIN=====
46
+ /*=======MAIN=====*/
47
47
  int main(void)
48
48
  {
49
49
  UnityBegin("test/TestProductionCode.c");
@@ -0,0 +1,257 @@
1
+ /* Unity Configuration
2
+ * As of May 11th, 2016 at ThrowTheSwitch/Unity commit 837c529
3
+ * See Also: Unity/docs/UnityConfigurationGuide.pdf
4
+ *
5
+ * Unity is designed to run on almost anything that is targeted by a C compiler.
6
+ * It would be awesome if this could be done with zero configuration. While
7
+ * there are some targets that come close to this dream, it is sadly not
8
+ * universal. It is likely that you are going to need at least a couple of the
9
+ * configuration options described in this document.
10
+ *
11
+ * All of Unity's configuration options are `#defines`. Most of these are simple
12
+ * definitions. A couple are macros with arguments. They live inside the
13
+ * unity_internals.h header file. We don't necessarily recommend opening that
14
+ * file unless you really need to. That file is proof that a cross-platform
15
+ * library is challenging to build. From a more positive perspective, it is also
16
+ * proof that a great deal of complexity can be centralized primarily to one
17
+ * place in order to provide a more consistent and simple experience elsewhere.
18
+ *
19
+ * Using These Options
20
+ * It doesn't matter if you're using a target-specific compiler and a simulator
21
+ * or a native compiler. In either case, you've got a couple choices for
22
+ * configuring these options:
23
+ *
24
+ * 1. Because these options are specified via C defines, you can pass most of
25
+ * these options to your compiler through command line compiler flags. Even
26
+ * if you're using an embedded target that forces you to use their
27
+ * overbearing IDE for all configuration, there will be a place somewhere in
28
+ * your project to configure defines for your compiler.
29
+ * 2. You can create a custom `unity_config.h` configuration file (present in
30
+ * your toolchain's search paths). In this file, you will list definitions
31
+ * and macros specific to your target. All you must do is define
32
+ * `UNITY_INCLUDE_CONFIG_H` and Unity will rely on `unity_config.h` for any
33
+ * further definitions it may need.
34
+ */
35
+
36
+ #ifndef UNITY_CONFIG_H
37
+ #define UNITY_CONFIG_H
38
+
39
+ #ifdef __cplusplus
40
+ extern "C"
41
+ {
42
+ #endif
43
+
44
+ /* ************************* AUTOMATIC INTEGER TYPES ***************************
45
+ * C's concept of an integer varies from target to target. The C Standard has
46
+ * rules about the `int` matching the register size of the target
47
+ * microprocessor. It has rules about the `int` and how its size relates to
48
+ * other integer types. An `int` on one target might be 16 bits while on another
49
+ * target it might be 64. There are more specific types in compilers compliant
50
+ * with C99 or later, but that's certainly not every compiler you are likely to
51
+ * encounter. Therefore, Unity has a number of features for helping to adjust
52
+ * itself to match your required integer sizes. It starts off by trying to do it
53
+ * automatically.
54
+ **************************************************************************** */
55
+
56
+ /* The first thing that Unity does to guess your types is check `stdint.h`. This
57
+ * file includes defines like `UINT_MAX` that Unity can make use of to learn a
58
+ * lot about your system. It's possible you don't want it to do this or it's
59
+ * possible that your system doesn't support `stdint.h`. If that's the case,
60
+ * you're going to want to define this. That way, Unity will know to skip the
61
+ * inclusion of this file and you won't be left with a compiler error.
62
+ */
63
+ /* #define UNITY_EXCLUDE_STDINT_H */
64
+
65
+ /* The second attempt to guess your types is to check `limits.h`. Some compilers
66
+ * that don't support `stdint.h` could include `limits.h` instead. If you don't
67
+ * want Unity to check this file either, define this to make it skip the
68
+ * inclusion.
69
+ */
70
+ /* #define UNITY_EXCLUDE_LIMITS_H */
71
+
72
+ /* The third and final attempt to guess your types is to use the `sizeof()`
73
+ * operator. Even if the first two options don't work, this one covers most
74
+ * cases. There _is_ a rare compiler or two out there that doesn't support
75
+ * `sizeof()` in the preprocessing stage, though. For these, you have the
76
+ * ability to disable this feature as well.
77
+ */
78
+ /* #define UNITY_EXCLUDE_SIZEOF */
79
+
80
+
81
+ /* ********************** MANUAL INTEGER TYPE DEFINITION ***********************
82
+ * If you've disabled all of the automatic options above, you're going to have
83
+ * to do the configuration yourself. There are just a handful of defines that
84
+ * you are going to specify if you don't like the defaults.
85
+ **************************************************************************** */
86
+
87
+ /* Define this to be the number of bits an `int` takes up on your system. The
88
+ * default, if not auto-detected, is 32 bits.
89
+ *
90
+ * Example:
91
+ */
92
+ /* #define UNITY_INT_WIDTH 16 */
93
+
94
+ /* Define this to be the number of bits a `long` takes up on your system. The
95
+ * default, if not autodetected, is 32 bits. This is used to figure out what
96
+ * kind of 64-bit support your system can handle. Does it need to specify a
97
+ * `long` or a `long long` to get a 64-bit value. On 16-bit systems, this option
98
+ * is going to be ignored.
99
+ *
100
+ * Example:
101
+ */
102
+ /* #define UNITY_LONG_WIDTH 16 */
103
+
104
+ /* Define this to be the number of bits a pointer takes up on your system. The
105
+ * default, if not autodetected, is 32-bits. If you're getting ugly compiler
106
+ * warnings about casting from pointers, this is the one to look at.
107
+ *
108
+ * Example:
109
+ */
110
+ /* #define UNITY_POINTER_WIDTH 64 */
111
+
112
+ /* Unity will automatically include 64-bit support if it auto-detects it, or if
113
+ * your `int`, `long`, or pointer widths are greater than 32-bits. Define this
114
+ * to enable 64-bit support if none of the other options already did it for you.
115
+ * There can be a significant size and speed impact to enabling 64-bit support
116
+ * on small targets, so don't define it if you don't need it.
117
+ */
118
+ /* #define UNITY_INCLUDE_64 */
119
+
120
+
121
+ /* *************************** FLOATING POINT TYPES ****************************
122
+ * In the embedded world, it's not uncommon for targets to have no support for
123
+ * floating point operations at all or to have support that is limited to only
124
+ * single precision. We are able to guess integer sizes on the fly because
125
+ * integers are always available in at least one size. Floating point, on the
126
+ * other hand, is sometimes not available at all. Trying to include `float.h` on
127
+ * these platforms would result in an error. This leaves manual configuration as
128
+ * the only option.
129
+ **************************************************************************** */
130
+
131
+ /* By default, Unity guesses that you will want single precision floating point
132
+ * support, but not double precision. It's easy to change either of these using
133
+ * the include and exclude options here. You may include neither, either, or
134
+ * both, as suits your needs.
135
+ */
136
+ /* #define UNITY_INCLUDE_FLOAT */
137
+ /* #define UNITY_EXCLUDE_FLOAT */
138
+ /* #define UNITY_INCLUDE_DOUBLE */
139
+ /* #define UNITY_EXCLUDE_DOUBLE */
140
+
141
+ /* For features that are enabled, the following floating point options also
142
+ * become available.
143
+ */
144
+
145
+ /* Unity aims for as small of a footprint as possible and avoids most standard
146
+ * library calls (some embedded platforms don't have a standard library!).
147
+ * Because of this, its routines for printing integer values are minimalist and
148
+ * hand-coded. To keep Unity universal, though, we chose to _not_ develop our
149
+ * own floating point print routines. Instead, the display of floating point
150
+ * values during a failure are optional. By default, Unity will not print the
151
+ * actual results of floating point assertion failure. So a failed assertion
152
+ * will produce a message like `"Values Not Within Delta"`. If you would like
153
+ * verbose failure messages for floating point assertions, use these options to
154
+ * give more explicit failure messages (e.g. `"Expected 4.56 Was 4.68"`). Note
155
+ * that this feature requires the use of `sprintf` so might not be desirable in
156
+ * all cases.
157
+ */
158
+ /* #define UNITY_FLOAT_VERBOSE */
159
+ /* #define UNITY_DOUBLE_VERBOSE */
160
+
161
+ /* If enabled, Unity assumes you want your `FLOAT` asserts to compare standard C
162
+ * floats. If your compiler supports a specialty floating point type, you can
163
+ * always override this behavior by using this definition.
164
+ *
165
+ * Example:
166
+ */
167
+ /* #define UNITY_FLOAT_TYPE float16_t */
168
+
169
+ /* If enabled, Unity assumes you want your `DOUBLE` asserts to compare standard
170
+ * C doubles. If you would like to change this, you can specify something else
171
+ * by using this option. For example, defining `UNITY_DOUBLE_TYPE` to `long
172
+ * double` could enable gargantuan floating point types on your 64-bit processor
173
+ * instead of the standard `double`.
174
+ *
175
+ * Example:
176
+ */
177
+ /* #define UNITY_DOUBLE_TYPE long double */
178
+
179
+ /* If you look up `UNITY_ASSERT_EQUAL_FLOAT` and `UNITY_ASSERT_EQUAL_DOUBLE` as
180
+ * documented in the Unity Assertion Guide, you will learn that they are not
181
+ * really asserting that two values are equal but rather that two values are
182
+ * "close enough" to equal. "Close enough" is controlled by these precision
183
+ * configuration options. If you are working with 32-bit floats and/or 64-bit
184
+ * doubles (the normal on most processors), you should have no need to change
185
+ * these options. They are both set to give you approximately 1 significant bit
186
+ * in either direction. The float precision is 0.00001 while the double is
187
+ * 10^-12. For further details on how this works, see the appendix of the Unity
188
+ * Assertion Guide.
189
+ *
190
+ * Example:
191
+ */
192
+ /* #define UNITY_FLOAT_PRECISION 0.001f */
193
+ /* #define UNITY_DOUBLE_PRECISION 0.001f */
194
+
195
+
196
+ /* *************************** TOOLSET CUSTOMIZATION ***************************
197
+ * In addition to the options listed above, there are a number of other options
198
+ * which will come in handy to customize Unity's behavior for your specific
199
+ * toolchain. It is possible that you may not need to touch any of these but
200
+ * certain platforms, particularly those running in simulators, may need to jump
201
+ * through extra hoops to operate properly. These macros will help in those
202
+ * situations.
203
+ **************************************************************************** */
204
+
205
+ /* By default, Unity prints its results to `stdout` as it runs. This works
206
+ * perfectly fine in most situations where you are using a native compiler for
207
+ * testing. It works on some simulators as well so long as they have `stdout`
208
+ * routed back to the command line. There are times, however, where the
209
+ * simulator will lack support for dumping results or you will want to route
210
+ * results elsewhere for other reasons. In these cases, you should define the
211
+ * `UNITY_OUTPUT_CHAR` macro. This macro accepts a single character at a time
212
+ * (as an `int`, since this is the parameter type of the standard C `putchar`
213
+ * function most commonly used). You may replace this with whatever function
214
+ * call you like.
215
+ *
216
+ * Example:
217
+ * Say you are forced to run your test suite on an embedded processor with no
218
+ * `stdout` option. You decide to route your test result output to a custom
219
+ * serial `RS232_putc()` function you wrote like thus:
220
+ */
221
+ /* #define UNITY_OUTPUT_CHAR(a) RS232_putc(a) */
222
+ /* #define UNITY_OUTPUT_FLUSH() RS232_config(115200,1,8,0) */
223
+ /* #define UNITY_OUTPUT_START() RS232_flush() */
224
+ /* #define UNITY_OUTPUT_COMPLETE() RS232_close() */
225
+
226
+ /* For some targets, Unity can make the otherwise required `setUp()` and
227
+ * `tearDown()` functions optional. This is a nice convenience for test writers
228
+ * since `setUp` and `tearDown` don't often actually _do_ anything. If you're
229
+ * using gcc or clang, this option is automatically defined for you. Other
230
+ * compilers can also support this behavior, if they support a C feature called
231
+ * weak functions. A weak function is a function that is compiled into your
232
+ * executable _unless_ a non-weak version of the same function is defined
233
+ * elsewhere. If a non-weak version is found, the weak version is ignored as if
234
+ * it never existed. If your compiler supports this feature, you can let Unity
235
+ * know by defining `UNITY_SUPPORT_WEAK` as the function attributes that would
236
+ * need to be applied to identify a function as weak. If your compiler lacks
237
+ * support for weak functions, you will always need to define `setUp` and
238
+ * `tearDown` functions (though they can be and often will be just empty). The
239
+ * most common options for this feature are:
240
+ */
241
+ /* #define UNITY_SUPPORT_WEAK weak */
242
+ /* #define UNITY_SUPPORT_WEAK __attribute__((weak)) */
243
+
244
+ /* Some compilers require a custom attribute to be assigned to pointers, like
245
+ * `near` or `far`. In these cases, you can give Unity a safe default for these
246
+ * by defining this option with the attribute you would like.
247
+ *
248
+ * Example:
249
+ */
250
+ /* #define UNITY_PTR_ATTRIBUTE __attribute__((far)) */
251
+ /* #define UNITY_PTR_ATTRIBUTE near */
252
+
253
+ #ifdef __cplusplus
254
+ }
255
+ #endif /* extern "C" */
256
+
257
+ #endif /* UNITY_CONFIG_H */
@@ -75,7 +75,6 @@ void UnityTestRunner(unityfunction* setup,
75
75
  {
76
76
  if (testSelected(name) && groupSelected(group))
77
77
  {
78
- Unity.CurrentTestFailed = 0;
79
78
  Unity.TestFile = file;
80
79
  Unity.CurrentTestName = printableName;
81
80
  Unity.CurrentTestLineNumber = line;
@@ -112,12 +111,14 @@ void UnityIgnoreTest(const char* printableName, const char* group, const char* n
112
111
  if (testSelected(name) && groupSelected(group))
113
112
  {
114
113
  Unity.NumberOfTests++;
115
- Unity.CurrentTestIgnored = 1;
114
+ Unity.TestIgnores++;
116
115
  if (!UnityFixture.Verbose)
117
116
  UNITY_OUTPUT_CHAR('!');
118
117
  else
118
+ {
119
119
  UnityPrint(printableName);
120
- UnityConcludeFixtureTest();
120
+ UNITY_PRINT_EOL();
121
+ }
121
122
  }
122
123
  }
123
124
 
@@ -206,6 +207,9 @@ void* unity_malloc(size_t size)
206
207
  mem = (char*)&(guard[1]);
207
208
  memcpy(&mem[size], end, sizeof(end));
208
209
 
210
+ #ifndef UNITY_FIXTURE_MALLOC_OVERRIDES_H_
211
+ free(guard);
212
+ #endif
209
213
  return (void*)mem;
210
214
  }
211
215
 
@@ -403,11 +407,8 @@ void UnityConcludeFixtureTest(void)
403
407
  {
404
408
  if (Unity.CurrentTestIgnored)
405
409
  {
406
- if (UnityFixture.Verbose)
407
- {
408
- UNITY_PRINT_EOL();
409
- }
410
410
  Unity.TestIgnores++;
411
+ UNITY_PRINT_EOL();
411
412
  }
412
413
  else if (!Unity.CurrentTestFailed)
413
414
  {
@@ -417,7 +418,7 @@ void UnityConcludeFixtureTest(void)
417
418
  UNITY_PRINT_EOL();
418
419
  }
419
420
  }
420
- else if (Unity.CurrentTestFailed)
421
+ else // Unity.CurrentTestFailed
421
422
  {
422
423
  Unity.TestFailures++;
423
424
  UNITY_PRINT_EOL();