ceedling 0.15.1 → 0.15.2

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 (295) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile +1 -1
  3. data/Gemfile.lock +9 -13
  4. data/README.md +21 -3
  5. data/{rakefile.rb → Rakefile} +0 -0
  6. data/lib/ceedling/version.rb +4 -4
  7. data/lib/ceedling/version.rb.erb +1 -1
  8. data/release/version.info +1 -1
  9. data/vendor/c_exception/Gemfile +1 -1
  10. data/vendor/c_exception/Gemfile.lock +12 -0
  11. data/vendor/c_exception/{docs/license.txt → LICENSE.txt} +9 -9
  12. data/vendor/c_exception/README.md +146 -0
  13. data/vendor/c_exception/{rakefile.rb → Rakefile} +6 -5
  14. data/vendor/c_exception/lib/CException.c +9 -6
  15. data/vendor/c_exception/release/build.info +1 -1
  16. data/vendor/c_exception/release/version.info +1 -1
  17. data/vendor/c_exception/test/CExceptionConfig.h +2 -0
  18. data/vendor/c_exception/test/TestException.c +4 -1
  19. data/vendor/cmock/README.md +24 -0
  20. data/vendor/cmock/{rakefile.rb → Rakefile} +12 -12
  21. data/vendor/cmock/docs/CMock Summary.odt +0 -0
  22. data/vendor/cmock/docs/CMock Summary.pdf +0 -0
  23. data/vendor/cmock/docs/CMock_Summary.md +130 -111
  24. data/vendor/cmock/docs/license.txt +1 -1
  25. data/vendor/cmock/lib/cmock.rb +36 -12
  26. data/vendor/cmock/lib/cmock_config.rb +39 -36
  27. data/vendor/cmock/lib/cmock_generator.rb +33 -25
  28. data/vendor/cmock/lib/cmock_generator_plugin_expect_any_args.rb +68 -0
  29. data/vendor/cmock/lib/cmock_generator_plugin_ignore.rb +18 -42
  30. data/vendor/cmock/lib/cmock_generator_plugin_return_thru_ptr.rb +2 -2
  31. data/vendor/cmock/lib/cmock_generator_utils.rb +39 -29
  32. data/vendor/cmock/lib/cmock_header_parser.rb +46 -39
  33. data/vendor/cmock/rakefile_helper.rb +38 -38
  34. data/vendor/cmock/src/cmock.c +20 -4
  35. data/vendor/cmock/src/cmock.h +6 -1
  36. data/vendor/cmock/src/cmock_internals.h +26 -3
  37. data/vendor/cmock/targets/clang_strict.yml +85 -0
  38. data/vendor/cmock/targets/gcc.yml +4 -2
  39. data/vendor/cmock/targets/gcc_64.yml +55 -0
  40. data/vendor/cmock/test/c/TestCMockC.c +3 -3
  41. data/vendor/cmock/test/c/TestCMockCDynamic.c +11 -11
  42. data/vendor/cmock/test/c/TestCMockCDynamic_Runner.c +4 -2
  43. data/vendor/cmock/test/c/TestCMockC_Runner.c +1 -1
  44. data/vendor/cmock/test/system/systest_generator.rb +38 -26
  45. data/vendor/cmock/test/system/test_compilation/const.h +8 -3
  46. data/vendor/cmock/test/system/test_interactions/all_plugins_but_other_limits.yml +92 -58
  47. data/vendor/cmock/test/system/test_interactions/all_plugins_coexist.yml +53 -48
  48. data/vendor/cmock/test/system/test_interactions/array_and_pointer_handling.yml +58 -56
  49. data/vendor/cmock/test/system/test_interactions/basic_expect_and_return.yml +19 -18
  50. data/vendor/cmock/test/system/test_interactions/expect_and_return_custom_types.yml +13 -13
  51. data/vendor/cmock/test/system/test_interactions/expect_and_return_treat_as.yml +20 -20
  52. data/vendor/cmock/test/system/test_interactions/expect_any_args.yml +238 -0
  53. data/vendor/cmock/test/system/test_interactions/fancy_pointer_handling.yml +36 -34
  54. data/vendor/cmock/test/system/test_interactions/ignore_and_return.yml +24 -15
  55. data/vendor/cmock/test/system/test_interactions/nonstandard_parsed_stuff_2.yml +11 -11
  56. data/vendor/cmock/test/system/test_interactions/return_thru_ptr_and_expect_any_args.yml +235 -0
  57. data/vendor/cmock/test/system/test_interactions/return_thru_ptr_ignore_arg.yml +22 -26
  58. data/vendor/cmock/test/system/test_interactions/stubs_with_callbacks.yml +31 -31
  59. data/vendor/cmock/test/unit/cmock_generator_main_test.rb +141 -109
  60. data/vendor/cmock/test/unit/cmock_generator_plugin_expect_any_args_test.rb +82 -0
  61. data/vendor/cmock/test/unit/cmock_generator_plugin_ignore_test.rb +17 -81
  62. data/vendor/cmock/test/unit/cmock_generator_plugin_return_thru_ptr_test.rb +10 -10
  63. data/vendor/cmock/test/unit/cmock_generator_utils_test.rb +47 -41
  64. data/vendor/cmock/test/unit/cmock_header_parser_test.rb +290 -227
  65. data/vendor/unity/{rakefile.rb → Rakefile} +13 -6
  66. data/vendor/unity/auto/colour_prompt.rb +33 -12
  67. data/vendor/unity/auto/generate_test_runner.rb +67 -63
  68. data/vendor/unity/auto/parseOutput.rb +189 -0
  69. data/vendor/{cmock/vendor/unity/examples → unity/examples/example_1}/makefile +41 -40
  70. data/vendor/unity/examples/example_1/readme.txt +5 -0
  71. data/vendor/{cmock/vendor/unity/examples → unity/examples/example_1}/src/ProductionCode.c +24 -24
  72. data/vendor/{c_exception/vendor/unity/examples → unity/examples/example_1}/src/ProductionCode.h +3 -3
  73. data/vendor/{cmock/vendor/unity/examples → unity/examples/example_1}/src/ProductionCode2.c +9 -9
  74. data/vendor/{c_exception/vendor/unity/examples → unity/examples/example_1}/src/ProductionCode2.h +2 -2
  75. data/vendor/{cmock/vendor/unity/examples → unity/examples/example_1}/test/TestProductionCode.c +62 -62
  76. data/vendor/unity/examples/{test → example_1/test}/TestProductionCode2.c +31 -31
  77. data/vendor/unity/examples/{test/no_ruby → example_1/test/test_runners}/TestProductionCode2_Runner.c +46 -46
  78. data/vendor/unity/examples/{test/no_ruby → example_1/test/test_runners}/TestProductionCode_Runner.c +50 -50
  79. data/vendor/unity/examples/example_2/makefile +45 -0
  80. data/vendor/unity/examples/example_2/readme.txt +5 -0
  81. data/vendor/unity/examples/{src → example_2/src}/ProductionCode.c +24 -24
  82. data/vendor/unity/examples/{src → example_2/src}/ProductionCode.h +3 -3
  83. data/vendor/unity/examples/{src → example_2/src}/ProductionCode2.c +9 -9
  84. data/vendor/unity/examples/{src → example_2/src}/ProductionCode2.h +2 -2
  85. data/vendor/unity/examples/{test → example_2/test}/TestProductionCode.c +64 -62
  86. data/vendor/{cmock/vendor/unity/examples → unity/examples/example_2}/test/TestProductionCode2.c +33 -31
  87. data/vendor/unity/examples/example_2/test/test_runners/TestProductionCode2_Runner.c +9 -0
  88. data/vendor/unity/examples/example_2/test/test_runners/TestProductionCode_Runner.c +11 -0
  89. data/vendor/unity/examples/example_2/test/test_runners/all_tests.c +12 -0
  90. data/vendor/unity/examples/{helper → example_3/helper}/UnityHelper.c +10 -10
  91. data/vendor/{cmock/vendor/unity/examples → unity/examples/example_3}/helper/UnityHelper.h +12 -12
  92. data/vendor/unity/examples/{makefile → example_3/makefile} +41 -40
  93. data/vendor/unity/examples/{rakefile.rb → example_3/rakefile.rb} +44 -43
  94. data/vendor/{cmock/vendor/unity/examples → unity/examples/example_3}/rakefile_helper.rb +256 -256
  95. data/vendor/{c_exception/vendor/unity/examples → unity/examples/example_3}/readme.txt +18 -17
  96. data/vendor/{c_exception/vendor/unity/examples → unity/examples/example_3}/src/ProductionCode.c +24 -24
  97. data/vendor/{cmock/vendor/unity/examples → unity/examples/example_3}/src/ProductionCode.h +3 -3
  98. data/vendor/{c_exception/vendor/unity/examples → unity/examples/example_3}/src/ProductionCode2.c +9 -9
  99. data/vendor/{cmock/vendor/unity/examples → unity/examples/example_3}/src/ProductionCode2.h +2 -2
  100. data/vendor/{c_exception/vendor/unity/targets/gcc_64.yml → unity/examples/example_3/target_gcc_32.yml} +46 -44
  101. data/vendor/{c_exception/vendor/unity/examples → unity/examples/example_3}/test/TestProductionCode.c +62 -62
  102. data/vendor/{c_exception/vendor/unity/examples → unity/examples/example_3}/test/TestProductionCode2.c +31 -31
  103. data/vendor/{c_exception/vendor/unity/examples → unity/examples/example_3}/test/no_ruby/TestProductionCode2_Runner.c +46 -46
  104. data/vendor/{cmock/vendor/unity/examples → unity/examples/example_3}/test/no_ruby/TestProductionCode_Runner.c +50 -50
  105. data/vendor/unity/extras/eclipse/error_parsers.txt +26 -0
  106. data/vendor/unity/extras/fixture/src/unity_fixture.c +4 -1
  107. data/vendor/unity/extras/fixture/src/unity_fixture.h +17 -16
  108. data/vendor/unity/extras/fixture/src/unity_fixture_internals.h +7 -7
  109. data/vendor/unity/extras/fixture/test/unity_fixture_Test.c +17 -0
  110. data/vendor/unity/extras/fixture/test/unity_fixture_TestRunner.c +1 -0
  111. data/vendor/unity/makefile +6 -4
  112. data/vendor/unity/rakefile_helper.rb +36 -27
  113. data/vendor/unity/src/unity.c +180 -181
  114. data/vendor/unity/src/unity.h +64 -2
  115. data/vendor/unity/src/unity_internals.h +188 -102
  116. data/vendor/unity/targets/clang_strict.yml +83 -0
  117. data/vendor/unity/targets/gcc_32.yml +5 -0
  118. data/vendor/unity/targets/gcc_64.yml +5 -0
  119. data/vendor/{c_exception/vendor/unity/targets/gcc.yml → unity/targets/gcc_auto_limits.yml} +5 -2
  120. data/vendor/{cmock/vendor/unity/targets/gcc_64.yml → unity/targets/gcc_auto_sizeof.yml} +6 -3
  121. data/vendor/{cmock/vendor/unity/targets/gcc.yml → unity/targets/gcc_auto_stdint.yml} +4 -2
  122. data/vendor/unity/test/expectdata/testsample_cmd.c +57 -54
  123. data/vendor/unity/test/expectdata/testsample_def.c +53 -50
  124. data/vendor/unity/test/expectdata/testsample_mock_cmd.c +79 -76
  125. data/vendor/unity/test/expectdata/testsample_mock_def.c +75 -72
  126. data/vendor/unity/test/expectdata/testsample_mock_new1.c +88 -85
  127. data/vendor/unity/test/expectdata/testsample_mock_new2.c +88 -85
  128. data/vendor/unity/test/expectdata/testsample_mock_param.c +76 -73
  129. data/vendor/unity/test/expectdata/testsample_mock_run1.c +88 -85
  130. data/vendor/unity/test/expectdata/testsample_mock_run2.c +88 -85
  131. data/vendor/unity/test/expectdata/testsample_mock_yaml.c +89 -86
  132. data/vendor/unity/test/expectdata/testsample_new1.c +63 -60
  133. data/vendor/unity/test/expectdata/testsample_new2.c +66 -63
  134. data/vendor/unity/test/expectdata/testsample_param.c +54 -51
  135. data/vendor/unity/test/expectdata/testsample_run1.c +63 -60
  136. data/vendor/unity/test/expectdata/testsample_run2.c +66 -63
  137. data/vendor/unity/test/expectdata/testsample_yaml.c +67 -64
  138. data/vendor/unity/test/test_generate_test_runner.rb +66 -72
  139. data/vendor/unity/test/testunity.c +591 -111
  140. metadata +58 -195
  141. data/vendor/c_exception/vendor/unity/auto/colour_prompt.rb +0 -94
  142. data/vendor/c_exception/vendor/unity/auto/colour_reporter.rb +0 -39
  143. data/vendor/c_exception/vendor/unity/auto/generate_config.yml +0 -36
  144. data/vendor/c_exception/vendor/unity/auto/generate_module.rb +0 -202
  145. data/vendor/c_exception/vendor/unity/auto/generate_test_runner.rb +0 -313
  146. data/vendor/c_exception/vendor/unity/auto/test_file_filter.rb +0 -23
  147. data/vendor/c_exception/vendor/unity/auto/unity_test_summary.rb +0 -139
  148. data/vendor/c_exception/vendor/unity/docs/Unity Summary.odt +0 -0
  149. data/vendor/c_exception/vendor/unity/docs/Unity Summary.pdf +0 -0
  150. data/vendor/c_exception/vendor/unity/docs/Unity Summary.txt +0 -217
  151. data/vendor/c_exception/vendor/unity/docs/license.txt +0 -31
  152. data/vendor/c_exception/vendor/unity/examples/helper/UnityHelper.c +0 -10
  153. data/vendor/c_exception/vendor/unity/examples/helper/UnityHelper.h +0 -12
  154. data/vendor/c_exception/vendor/unity/examples/makefile +0 -40
  155. data/vendor/c_exception/vendor/unity/examples/rakefile.rb +0 -32
  156. data/vendor/c_exception/vendor/unity/examples/rakefile_helper.rb +0 -256
  157. data/vendor/c_exception/vendor/unity/examples/test/no_ruby/TestProductionCode_Runner.c +0 -50
  158. data/vendor/c_exception/vendor/unity/extras/fixture/build/MakefileWorker.mk +0 -331
  159. data/vendor/c_exception/vendor/unity/extras/fixture/build/filterGcov.sh +0 -61
  160. data/vendor/c_exception/vendor/unity/extras/fixture/rakefile.rb +0 -37
  161. data/vendor/c_exception/vendor/unity/extras/fixture/rakefile_helper.rb +0 -178
  162. data/vendor/c_exception/vendor/unity/extras/fixture/readme.txt +0 -9
  163. data/vendor/c_exception/vendor/unity/extras/fixture/src/unity_fixture.c +0 -381
  164. data/vendor/c_exception/vendor/unity/extras/fixture/src/unity_fixture.h +0 -81
  165. data/vendor/c_exception/vendor/unity/extras/fixture/src/unity_fixture_internals.h +0 -44
  166. data/vendor/c_exception/vendor/unity/extras/fixture/src/unity_fixture_malloc_overrides.h +0 -16
  167. data/vendor/c_exception/vendor/unity/extras/fixture/test/main/AllTests.c +0 -21
  168. data/vendor/c_exception/vendor/unity/extras/fixture/test/testunity_fixture.c +0 -39
  169. data/vendor/c_exception/vendor/unity/extras/fixture/test/unity_fixture_Test.c +0 -321
  170. data/vendor/c_exception/vendor/unity/extras/fixture/test/unity_fixture_TestRunner.c +0 -40
  171. data/vendor/c_exception/vendor/unity/extras/fixture/test/unity_output_Spy.c +0 -56
  172. data/vendor/c_exception/vendor/unity/extras/fixture/test/unity_output_Spy.h +0 -17
  173. data/vendor/c_exception/vendor/unity/makefile +0 -35
  174. data/vendor/c_exception/vendor/unity/rakefile.rb +0 -59
  175. data/vendor/c_exception/vendor/unity/rakefile_helper.rb +0 -240
  176. data/vendor/c_exception/vendor/unity/release/build.info +0 -2
  177. data/vendor/c_exception/vendor/unity/release/version.info +0 -2
  178. data/vendor/c_exception/vendor/unity/src/unity.c +0 -979
  179. data/vendor/c_exception/vendor/unity/src/unity.h +0 -232
  180. data/vendor/c_exception/vendor/unity/src/unity_internals.h +0 -424
  181. data/vendor/c_exception/vendor/unity/targets/hitech_picc18.yml +0 -101
  182. data/vendor/c_exception/vendor/unity/targets/iar_arm_v4.yml +0 -89
  183. data/vendor/c_exception/vendor/unity/targets/iar_arm_v5.yml +0 -79
  184. data/vendor/c_exception/vendor/unity/targets/iar_arm_v5_3.yml +0 -79
  185. data/vendor/c_exception/vendor/unity/targets/iar_armcortex_LM3S9B92_v5_4.yml +0 -93
  186. data/vendor/c_exception/vendor/unity/targets/iar_cortexm3_v5.yml +0 -83
  187. data/vendor/c_exception/vendor/unity/targets/iar_msp430.yml +0 -94
  188. data/vendor/c_exception/vendor/unity/targets/iar_sh2a_v6.yml +0 -85
  189. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_cmd.c +0 -54
  190. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_def.c +0 -50
  191. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_cmd.c +0 -76
  192. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_def.c +0 -72
  193. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_new1.c +0 -85
  194. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_new2.c +0 -85
  195. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_param.c +0 -73
  196. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_run1.c +0 -85
  197. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_run2.c +0 -85
  198. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_yaml.c +0 -86
  199. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_new1.c +0 -60
  200. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_new2.c +0 -63
  201. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_param.c +0 -51
  202. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_run1.c +0 -60
  203. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_run2.c +0 -63
  204. data/vendor/c_exception/vendor/unity/test/expectdata/testsample_yaml.c +0 -64
  205. data/vendor/c_exception/vendor/unity/test/test_generate_test_runner.rb +0 -94
  206. data/vendor/c_exception/vendor/unity/test/testdata/mocksample.c +0 -51
  207. data/vendor/c_exception/vendor/unity/test/testdata/sample.yml +0 -9
  208. data/vendor/c_exception/vendor/unity/test/testdata/testsample.c +0 -51
  209. data/vendor/c_exception/vendor/unity/test/testparameterized.c +0 -101
  210. data/vendor/c_exception/vendor/unity/test/testunity.c +0 -2024
  211. data/vendor/cmock/vendor/c_exception/docs/CExceptionSummary.odt +0 -0
  212. data/vendor/cmock/vendor/c_exception/docs/CExceptionSummary.pdf +0 -0
  213. data/vendor/cmock/vendor/c_exception/docs/license.txt +0 -30
  214. data/vendor/cmock/vendor/c_exception/docs/readme.txt +0 -236
  215. data/vendor/cmock/vendor/c_exception/lib/CException.c +0 -39
  216. data/vendor/cmock/vendor/c_exception/lib/CException.h +0 -70
  217. data/vendor/cmock/vendor/c_exception/makefile +0 -24
  218. data/vendor/cmock/vendor/c_exception/rakefile.rb +0 -41
  219. data/vendor/cmock/vendor/c_exception/release/build.info +0 -2
  220. data/vendor/cmock/vendor/c_exception/release/version.info +0 -2
  221. data/vendor/cmock/vendor/c_exception/test/CExceptionConfig.h +0 -27
  222. data/vendor/cmock/vendor/c_exception/test/TestException.c +0 -291
  223. data/vendor/cmock/vendor/c_exception/test/TestException_Runner.c +0 -62
  224. data/vendor/cmock/vendor/unity/auto/colour_prompt.rb +0 -94
  225. data/vendor/cmock/vendor/unity/auto/colour_reporter.rb +0 -39
  226. data/vendor/cmock/vendor/unity/auto/generate_config.yml +0 -36
  227. data/vendor/cmock/vendor/unity/auto/generate_module.rb +0 -202
  228. data/vendor/cmock/vendor/unity/auto/generate_test_runner.rb +0 -313
  229. data/vendor/cmock/vendor/unity/auto/test_file_filter.rb +0 -23
  230. data/vendor/cmock/vendor/unity/auto/unity_test_summary.rb +0 -139
  231. data/vendor/cmock/vendor/unity/docs/Unity Summary.odt +0 -0
  232. data/vendor/cmock/vendor/unity/docs/Unity Summary.pdf +0 -0
  233. data/vendor/cmock/vendor/unity/docs/Unity Summary.txt +0 -217
  234. data/vendor/cmock/vendor/unity/docs/license.txt +0 -31
  235. data/vendor/cmock/vendor/unity/examples/helper/UnityHelper.c +0 -10
  236. data/vendor/cmock/vendor/unity/examples/rakefile.rb +0 -32
  237. data/vendor/cmock/vendor/unity/examples/readme.txt +0 -18
  238. data/vendor/cmock/vendor/unity/examples/test/no_ruby/TestProductionCode2_Runner.c +0 -46
  239. data/vendor/cmock/vendor/unity/extras/fixture/build/MakefileWorker.mk +0 -331
  240. data/vendor/cmock/vendor/unity/extras/fixture/build/filterGcov.sh +0 -61
  241. data/vendor/cmock/vendor/unity/extras/fixture/rakefile.rb +0 -37
  242. data/vendor/cmock/vendor/unity/extras/fixture/rakefile_helper.rb +0 -178
  243. data/vendor/cmock/vendor/unity/extras/fixture/readme.txt +0 -9
  244. data/vendor/cmock/vendor/unity/extras/fixture/src/unity_fixture.c +0 -381
  245. data/vendor/cmock/vendor/unity/extras/fixture/src/unity_fixture.h +0 -81
  246. data/vendor/cmock/vendor/unity/extras/fixture/src/unity_fixture_internals.h +0 -44
  247. data/vendor/cmock/vendor/unity/extras/fixture/src/unity_fixture_malloc_overrides.h +0 -16
  248. data/vendor/cmock/vendor/unity/extras/fixture/test/main/AllTests.c +0 -21
  249. data/vendor/cmock/vendor/unity/extras/fixture/test/testunity_fixture.c +0 -39
  250. data/vendor/cmock/vendor/unity/extras/fixture/test/unity_fixture_Test.c +0 -321
  251. data/vendor/cmock/vendor/unity/extras/fixture/test/unity_fixture_TestRunner.c +0 -40
  252. data/vendor/cmock/vendor/unity/extras/fixture/test/unity_output_Spy.c +0 -56
  253. data/vendor/cmock/vendor/unity/extras/fixture/test/unity_output_Spy.h +0 -17
  254. data/vendor/cmock/vendor/unity/makefile +0 -35
  255. data/vendor/cmock/vendor/unity/rakefile.rb +0 -48
  256. data/vendor/cmock/vendor/unity/rakefile_helper.rb +0 -240
  257. data/vendor/cmock/vendor/unity/release/build.info +0 -2
  258. data/vendor/cmock/vendor/unity/release/version.info +0 -2
  259. data/vendor/cmock/vendor/unity/src/unity.c +0 -979
  260. data/vendor/cmock/vendor/unity/src/unity.h +0 -232
  261. data/vendor/cmock/vendor/unity/src/unity_internals.h +0 -424
  262. data/vendor/cmock/vendor/unity/targets/hitech_picc18.yml +0 -101
  263. data/vendor/cmock/vendor/unity/targets/iar_arm_v4.yml +0 -89
  264. data/vendor/cmock/vendor/unity/targets/iar_arm_v5.yml +0 -79
  265. data/vendor/cmock/vendor/unity/targets/iar_arm_v5_3.yml +0 -79
  266. data/vendor/cmock/vendor/unity/targets/iar_armcortex_LM3S9B92_v5_4.yml +0 -93
  267. data/vendor/cmock/vendor/unity/targets/iar_cortexm3_v5.yml +0 -83
  268. data/vendor/cmock/vendor/unity/targets/iar_msp430.yml +0 -94
  269. data/vendor/cmock/vendor/unity/targets/iar_sh2a_v6.yml +0 -85
  270. data/vendor/cmock/vendor/unity/test/expectdata/testsample_cmd.c +0 -54
  271. data/vendor/cmock/vendor/unity/test/expectdata/testsample_def.c +0 -50
  272. data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_cmd.c +0 -76
  273. data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_def.c +0 -72
  274. data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_new1.c +0 -85
  275. data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_new2.c +0 -85
  276. data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_param.c +0 -73
  277. data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_run1.c +0 -85
  278. data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_run2.c +0 -85
  279. data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_yaml.c +0 -86
  280. data/vendor/cmock/vendor/unity/test/expectdata/testsample_new1.c +0 -60
  281. data/vendor/cmock/vendor/unity/test/expectdata/testsample_new2.c +0 -63
  282. data/vendor/cmock/vendor/unity/test/expectdata/testsample_param.c +0 -51
  283. data/vendor/cmock/vendor/unity/test/expectdata/testsample_run1.c +0 -60
  284. data/vendor/cmock/vendor/unity/test/expectdata/testsample_run2.c +0 -63
  285. data/vendor/cmock/vendor/unity/test/expectdata/testsample_yaml.c +0 -64
  286. data/vendor/cmock/vendor/unity/test/test_generate_test_runner.rb +0 -94
  287. data/vendor/cmock/vendor/unity/test/testdata/mocksample.c +0 -51
  288. data/vendor/cmock/vendor/unity/test/testdata/sample.yml +0 -9
  289. data/vendor/cmock/vendor/unity/test/testdata/testsample.c +0 -51
  290. data/vendor/cmock/vendor/unity/test/testparameterized.c +0 -101
  291. data/vendor/cmock/vendor/unity/test/testunity.c +0 -2024
  292. data/vendor/unity/Gemfile +0 -4
  293. data/vendor/unity/examples/helper/UnityHelper.h +0 -12
  294. data/vendor/unity/examples/rakefile_helper.rb +0 -256
  295. data/vendor/unity/examples/readme.txt +0 -18
@@ -3,7 +3,7 @@
3
3
  :plugins:
4
4
  - # none
5
5
  :memcmp_if_unknown: false
6
-
6
+
7
7
  :systest:
8
8
  :types: |
9
9
  typedef struct _EXAMPLE_STRUCT_T { int x; int y; } EXAMPLE_STRUCT_T;
@@ -11,34 +11,34 @@
11
11
  :mockable: |
12
12
  EXAMPLE_STRUCT_T foo(EXAMPLE_STRUCT_T a);
13
13
 
14
- :source:
15
- :header: |
14
+ :source:
15
+ :header: |
16
16
  EXAMPLE_STRUCT_T function_a(EXAMPLE_STRUCT_T a, EXAMPLE_STRUCT_T b);
17
17
  EXAMPLE_STRUCT_T function_b(EXAMPLE_STRUCT_T a, EXAMPLE_STRUCT_T b);
18
18
 
19
19
  :code: |
20
- EXAMPLE_STRUCT_T function_a(EXAMPLE_STRUCT_T a, EXAMPLE_STRUCT_T b)
20
+ EXAMPLE_STRUCT_T function_a(EXAMPLE_STRUCT_T a, EXAMPLE_STRUCT_T b)
21
21
  {
22
22
  EXAMPLE_STRUCT_T retval = foo(a);
23
23
  retval.x += b.x;
24
24
  retval.y += b.y;
25
25
  return retval;
26
- }
27
-
28
- EXAMPLE_STRUCT_T function_b(EXAMPLE_STRUCT_T a, EXAMPLE_STRUCT_T b)
26
+ }
27
+
28
+ EXAMPLE_STRUCT_T function_b(EXAMPLE_STRUCT_T a, EXAMPLE_STRUCT_T b)
29
29
  {
30
30
  EXAMPLE_STRUCT_T retval = foo(b);
31
31
  retval.x *= a.x;
32
32
  retval.y *= a.y;
33
33
  return retval;
34
- }
34
+ }
35
35
 
36
36
  :tests:
37
37
  :common: |
38
38
  #include "expect_and_return_custom_types_unity_helper.h"
39
39
  void setUp(void) {}
40
40
  void tearDown(void) {}
41
-
41
+
42
42
  :units:
43
43
  - :pass: TRUE
44
44
  :should: 'successfully exercise simple ExpectAndReturn mock calls'
@@ -52,7 +52,7 @@
52
52
  foo_ExpectAndReturn(c, e);
53
53
  TEST_ASSERT_EQUAL_EXAMPLE_STRUCT_T(f, function_a(c,d));
54
54
  }
55
-
55
+
56
56
  - :pass: FALSE
57
57
  :should: 'fail because it is expecting to call foo with c not d'
58
58
  :code: |
@@ -65,7 +65,7 @@
65
65
  foo_ExpectAndReturn(d, e);
66
66
  TEST_ASSERT_EQUAL_EXAMPLE_STRUCT_T(f, function_a(c,d));
67
67
  }
68
-
68
+
69
69
  - :pass: TRUE
70
70
  :should: 'successfully exercise simple ExpectAndReturn mock calls on other function'
71
71
  :code: |
@@ -78,7 +78,7 @@
78
78
  foo_ExpectAndReturn(d, e);
79
79
  TEST_ASSERT_EQUAL_EXAMPLE_STRUCT_T(f, function_b(c,d));
80
80
  }
81
-
81
+
82
82
  - :pass: FALSE
83
83
  :should: 'fail because it is expecting to call foo with d not c'
84
84
  :code: |
@@ -95,7 +95,7 @@
95
95
  :unity_helper:
96
96
  :header: |
97
97
  void AssertEqualExampleStruct(EXAMPLE_STRUCT_T expected, EXAMPLE_STRUCT_T actual, unsigned short line);
98
- #define UNITY_TEST_ASSERT_EQUAL_EXAMPLE_STRUCT_T(expected, actual, line, message) {AssertEqualExampleStruct(expected, actual, line);}
98
+ #define UNITY_TEST_ASSERT_EQUAL_EXAMPLE_STRUCT_T(expected, actual, line, message) {AssertEqualExampleStruct(expected, actual, (unsigned short)line);}
99
99
  #define TEST_ASSERT_EQUAL_EXAMPLE_STRUCT_T(expected, actual) UNITY_TEST_ASSERT_EQUAL_EXAMPLE_STRUCT_T(expected, actual, __LINE__, NULL);
100
100
 
101
101
  :code: |
@@ -10,7 +10,7 @@
10
10
 
11
11
  :systest:
12
12
  :types: |
13
- typedef char* MY_STRING;
13
+ typedef const char* MY_STRING;
14
14
  typedef int MY_INT;
15
15
  typedef unsigned int MY_HEX;
16
16
  typedef int* PTR_INT;
@@ -23,8 +23,8 @@
23
23
  MY_INT* pointer_foo(MY_HEX* a);
24
24
  void pointer_bar(PTR_INT a);
25
25
 
26
- :source:
27
- :header: |
26
+ :source:
27
+ :header: |
28
28
  MY_INT function_a(MY_INT a, MY_INT b);
29
29
  MY_STRING function_b(MY_STRING a, MY_STRING b);
30
30
  float function_c(float a, float b);
@@ -32,38 +32,38 @@
32
32
  void function_e(PTR_INT a);
33
33
 
34
34
  :code: |
35
- MY_INT function_a(MY_INT a, MY_INT b)
35
+ MY_INT function_a(MY_INT a, MY_INT b)
36
36
  {
37
37
  return foo((MY_HEX)a) + bar((MY_HEX)b);
38
- }
39
-
38
+ }
39
+
40
40
  MY_STRING function_b(MY_STRING a, MY_STRING b)
41
41
  {
42
42
  return foo_char_strings(a, b);
43
43
  }
44
-
44
+
45
45
  float function_c(float a, float b)
46
46
  {
47
47
  return float_adder(b, a);
48
48
  }
49
-
49
+
50
50
  MY_INT function_d(MY_HEX a)
51
51
  {
52
52
  MY_HEX b = a;
53
53
  MY_INT* c = pointer_foo(&b);
54
54
  return *c;
55
55
  }
56
-
56
+
57
57
  void function_e(PTR_INT a)
58
58
  {
59
59
  pointer_bar(a);
60
60
  }
61
-
61
+
62
62
  :tests:
63
63
  :common: |
64
64
  void setUp(void) {}
65
65
  void tearDown(void) {}
66
-
66
+
67
67
  :units:
68
68
  - :pass: TRUE
69
69
  :should: 'successfully exercise two simple ExpectAndReturn mock calls'
@@ -74,7 +74,7 @@
74
74
  bar_ExpectAndReturn((MY_HEX)2, 20);
75
75
  TEST_ASSERT_EQUAL(30, function_a(1, 2));
76
76
  }
77
-
77
+
78
78
  - :pass: FALSE
79
79
  :should: 'fail because bar() is expected but not called'
80
80
  :code: |
@@ -107,8 +107,8 @@
107
107
  :code: |
108
108
  test()
109
109
  {
110
- float_adder_ExpectAndReturn(1.2345, 6.7890, 8.0235);
111
- TEST_ASSERT_EQUAL_FLOAT(8.0235, function_c(6.7890, 1.2345));
110
+ float_adder_ExpectAndReturn(1.2345f, 6.7890f, 8.0235f);
111
+ TEST_ASSERT_EQUAL_FLOAT(8.0235f, function_c(6.7890f, 1.2345f));
112
112
  }
113
113
 
114
114
  - :pass: FALSE
@@ -116,10 +116,10 @@
116
116
  :code: |
117
117
  test()
118
118
  {
119
- float_adder_ExpectAndReturn(1.2345, 6.7892, 8.0235);
120
- TEST_ASSERT_EQUAL_FLOAT(8.0235, function_c(6.7890, 1.2345));
119
+ float_adder_ExpectAndReturn(1.2345f, 6.7892f, 8.0235f);
120
+ TEST_ASSERT_EQUAL_FLOAT(8.0235f, function_c(6.7890f, 1.2345f));
121
121
  }
122
-
122
+
123
123
  - :pass: TRUE
124
124
  :should: 'handle pointers to treat_as values just as cleanly as the treat_as itself for passes'
125
125
  :code: |
@@ -130,7 +130,7 @@
130
130
  pointer_foo_ExpectAndReturn(&TestHex, &TestInt);
131
131
  TEST_ASSERT_EQUAL_INT(33, function_d(45));
132
132
  }
133
-
133
+
134
134
  - :pass: FALSE
135
135
  :should: 'handle pointers to treat_as values just as cleanly as the treat_as itself for failures'
136
136
  :verify_error: 'Element 0 Expected 0x0000002D Was 0x0000002B'
@@ -142,7 +142,7 @@
142
142
  pointer_foo_ExpectAndReturn(&TestHex, &TestInt);
143
143
  TEST_ASSERT_EQUAL_INT(33, function_d(43));
144
144
  }
145
-
145
+
146
146
  - :pass: TRUE
147
147
  :should: 'handle treat_as values containing pointers for passes'
148
148
  :code: |
@@ -155,7 +155,7 @@
155
155
  pointer_bar_Expect(ExpPtr);
156
156
  function_e(ActPtr);
157
157
  }
158
-
158
+
159
159
  - :pass: FALSE
160
160
  :should: 'handle treat_as values containing pointers for failures'
161
161
  :verify_error: 'Element 0 Expected 33 Was 45'
@@ -0,0 +1,238 @@
1
+ ---
2
+ :cmock:
3
+ :plugins:
4
+ - 'expect_any_args'
5
+
6
+ :systest:
7
+ :types: |
8
+
9
+ :mockable: |
10
+ int foo(int a);
11
+ void bar(int b);
12
+
13
+ :source:
14
+ :header: |
15
+ int function(int a, int b, int c);
16
+ void func_b(int a);
17
+ :code: |
18
+ int function(int a, int b, int c)
19
+ {
20
+ bar(b);
21
+ return foo(a) + foo(b) + foo(c);
22
+ }
23
+ void func_b(int a)
24
+ {
25
+ bar(a);
26
+ }
27
+
28
+ :tests:
29
+ :common: |
30
+ void setUp(void) {}
31
+ void tearDown(void) {}
32
+ :units:
33
+ - :pass: TRUE
34
+ :should: 'successfully exercise simple ExpectAndReturn mock calls'
35
+ :code: |
36
+ test()
37
+ {
38
+ bar_Expect(2);
39
+ foo_ExpectAndReturn(1, 10);
40
+ foo_ExpectAndReturn(2, 20);
41
+ foo_ExpectAndReturn(3, 30);
42
+ TEST_ASSERT_EQUAL(60, function(1, 2, 3));
43
+ }
44
+
45
+ - :pass: TRUE
46
+ :should: 'ignore foo() call details'
47
+ :code: |
48
+ test()
49
+ {
50
+ bar_Expect(4);
51
+ foo_ExpectAnyArgsAndReturn(10);
52
+ foo_ExpectAnyArgsAndReturn(40);
53
+ foo_ExpectAnyArgsAndReturn(80);
54
+ TEST_ASSERT_EQUAL(130, function(3, 4, 3));
55
+ }
56
+
57
+ - :pass: FALSE
58
+ :should: 'ignore foo() call details and notice if we called foo() more times than expected'
59
+ :code: |
60
+ test()
61
+ {
62
+ bar_Expect(4);
63
+ foo_ExpectAnyArgsAndReturn(20);
64
+ foo_ExpectAnyArgsAndReturn(30);
65
+ TEST_ASSERT_EQUAL(50, function(3, 4, 9));
66
+ }
67
+
68
+ - :pass: FALSE
69
+ :should: 'ignore foo() call details and notice if we called foo() less times than expected'
70
+ :code: |
71
+ test()
72
+ {
73
+ bar_Expect(4);
74
+ foo_ExpectAnyArgsAndReturn(20);
75
+ foo_ExpectAnyArgsAndReturn(10);
76
+ foo_ExpectAnyArgsAndReturn(50);
77
+ foo_ExpectAnyArgsAndReturn(60);
78
+ TEST_ASSERT_EQUAL(70, function(3, 4, 9));
79
+ }
80
+
81
+ - :pass: TRUE
82
+ :should: 'ignore bar() and foo() call details'
83
+ :code: |
84
+ test()
85
+ {
86
+ bar_ExpectAnyArgs();
87
+ foo_ExpectAnyArgsAndReturn(50);
88
+ foo_ExpectAnyArgsAndReturn(50);
89
+ foo_ExpectAnyArgsAndReturn(50);
90
+ TEST_ASSERT_EQUAL(150, function(0, 0, 0));
91
+ }
92
+
93
+ - :pass: TRUE
94
+ :should: 'be able to handle an expect after ignore calls since we are ignoring args only'
95
+ :code: |
96
+ test()
97
+ {
98
+ bar_ExpectAnyArgs();
99
+ foo_ExpectAnyArgsAndReturn(50);
100
+ foo_ExpectAnyArgsAndReturn(50);
101
+ foo_ExpectAndReturn(3, 50);
102
+ TEST_ASSERT_EQUAL(150, function(1, 2, 3));
103
+ }
104
+
105
+ - :pass: TRUE
106
+ :should: 'be able to handle an ignore after an expect call since we are ignoring args only'
107
+ :code: |
108
+ test()
109
+ {
110
+ bar_ExpectAnyArgs();
111
+ foo_ExpectAndReturn(1, 50);
112
+ foo_ExpectAnyArgsAndReturn(50);
113
+ foo_ExpectAnyArgsAndReturn(50);
114
+ TEST_ASSERT_EQUAL(150, function(1, 2, 3));
115
+ }
116
+
117
+ - :pass: TRUE
118
+ :should: 'be able to handle an ignore within expect calls since we are ignoring args only'
119
+ :code: |
120
+ test()
121
+ {
122
+ bar_ExpectAnyArgs();
123
+ foo_ExpectAndReturn(1, 50);
124
+ foo_ExpectAnyArgsAndReturn(50);
125
+ foo_ExpectAndReturn(3, 50);
126
+ TEST_ASSERT_EQUAL(150, function(1, 2, 3));
127
+ }
128
+
129
+ - :pass: FALSE
130
+ :should: 'be able to detect problems with an expect even when using ignores'
131
+ :code: |
132
+ test()
133
+ {
134
+ bar_ExpectAnyArgs();
135
+ foo_ExpectAndReturn(1, 50);
136
+ foo_ExpectAnyArgsAndReturn(50);
137
+ foo_ExpectAndReturn(4, 50);
138
+ TEST_ASSERT_EQUAL(150, function(1, 2, 3));
139
+ }
140
+
141
+ - :pass: TRUE
142
+ :should: 'be able to handle a lone ExpectAnyArg call'
143
+ :code: |
144
+ test()
145
+ {
146
+ bar_ExpectAnyArgs();
147
+ func_b(1);
148
+ }
149
+
150
+ - :pass: FALSE
151
+ :should: 'be able to handle a lone ExpectAnyArg call that does not get called'
152
+ :code: |
153
+ test()
154
+ {
155
+ bar_ExpectAnyArgs();
156
+ }
157
+
158
+ - :pass: FALSE
159
+ :should: 'be able to handle a missing ExpectAnyArg call'
160
+ :code: |
161
+ test()
162
+ {
163
+ func_b(1);
164
+ }
165
+
166
+ - :pass: TRUE
167
+ :should: 'ignore foo() calls over multiple mock calls'
168
+ :code: |
169
+ test()
170
+ {
171
+ bar_ExpectAnyArgs();
172
+ foo_ExpectAnyArgsAndReturn(50);
173
+ foo_ExpectAnyArgsAndReturn(60);
174
+ foo_ExpectAnyArgsAndReturn(70);
175
+ TEST_ASSERT_EQUAL(180, function(0, 0, 0));
176
+
177
+ bar_ExpectAnyArgs();
178
+ foo_ExpectAnyArgsAndReturn(30);
179
+ foo_ExpectAnyArgsAndReturn(80);
180
+ foo_ExpectAnyArgsAndReturn(10);
181
+ TEST_ASSERT_EQUAL(120, function(0, 0, 0));
182
+
183
+ bar_ExpectAnyArgs();
184
+ foo_ExpectAnyArgsAndReturn(70);
185
+ foo_ExpectAnyArgsAndReturn(20);
186
+ foo_ExpectAnyArgsAndReturn(20);
187
+ TEST_ASSERT_EQUAL(110, function(0, 0, 0));
188
+ }
189
+
190
+ - :pass: TRUE
191
+ :should: 'have multiple cycles of expects still pass when this plugin enabled'
192
+ :code: |
193
+ test()
194
+ {
195
+ bar_Expect(2);
196
+ foo_ExpectAndReturn(1, 50);
197
+ foo_ExpectAndReturn(2, 60);
198
+ foo_ExpectAndReturn(3, 70);
199
+ TEST_ASSERT_EQUAL(180, function(1, 2, 3));
200
+
201
+ bar_Expect(5);
202
+ foo_ExpectAndReturn(4, 30);
203
+ foo_ExpectAndReturn(5, 80);
204
+ foo_ExpectAndReturn(6, 10);
205
+ TEST_ASSERT_EQUAL(120, function(4, 5, 6));
206
+
207
+ bar_Expect(8);
208
+ foo_ExpectAndReturn(7, 70);
209
+ foo_ExpectAndReturn(8, 20);
210
+ foo_ExpectAndReturn(9, 20);
211
+ TEST_ASSERT_EQUAL(110, function(7, 8, 9));
212
+ }
213
+
214
+ - :pass: FALSE
215
+ :should: 'have multiple cycles of expects still fail when this plugin enabled'
216
+ :code: |
217
+ test()
218
+ {
219
+ bar_Expect(2);
220
+ foo_ExpectAndReturn(1, 50);
221
+ foo_ExpectAndReturn(2, 60);
222
+ foo_ExpectAndReturn(3, 70);
223
+ TEST_ASSERT_EQUAL(180, function(1, 2, 3));
224
+
225
+ bar_Expect(5);
226
+ foo_ExpectAndReturn(4, 30);
227
+ foo_ExpectAndReturn(5, 80);
228
+ foo_ExpectAndReturn(6, 10);
229
+ TEST_ASSERT_EQUAL(120, function(4, 5, 6));
230
+
231
+ bar_Expect(8);
232
+ foo_ExpectAndReturn(7, 70);
233
+ foo_ExpectAndReturn(8, 20);
234
+ foo_ExpectAndReturn(9, 20);
235
+ TEST_ASSERT_EQUAL(110, function(0, 8, 9));
236
+ }
237
+
238
+ ...
@@ -3,7 +3,7 @@
3
3
  :plugins:
4
4
  - # none
5
5
  :treat_as:
6
- INT_PTR: INT*
6
+ INT_PTR: INT*
7
7
 
8
8
  :systest:
9
9
  :types: |
@@ -21,38 +21,38 @@
21
21
  const char* bars(void);
22
22
  INT_PTR zoink(INT_PTR a);
23
23
 
24
- :source:
25
- :header: |
24
+ :source:
25
+ :header: |
26
26
  void function_a(void);
27
27
  void function_b(void);
28
28
  void function_c(void);
29
29
  int function_d(void);
30
30
 
31
31
  :code: |
32
- void function_a(void)
32
+ void function_a(void)
33
33
  {
34
34
  foo(bar());
35
- }
35
+ }
36
36
 
37
37
  void function_b(void) {
38
38
  fooa(bar());
39
39
  }
40
-
40
+
41
41
  void function_c(void) {
42
42
  foos(bars());
43
43
  }
44
-
44
+
45
45
  int function_d(void) {
46
46
  int i = 456;
47
47
  INT_PTR ptr = (INT_PTR)(&i);
48
48
  return (int)(*(zoink(ptr)));
49
49
  }
50
-
50
+
51
51
  :tests:
52
52
  :common: |
53
53
  void setUp(void) {}
54
54
  void tearDown(void) {}
55
-
55
+
56
56
  :units:
57
57
  - :pass: TRUE
58
58
  :should: 'handle the situation where we pass nulls to pointers'
@@ -61,10 +61,10 @@
61
61
  {
62
62
  bar_ExpectAndReturn(NULL);
63
63
  foo_Expect(NULL);
64
-
64
+
65
65
  function_a();
66
66
  }
67
-
67
+
68
68
  - :pass: TRUE
69
69
  :should: 'handle the situation where we pass single object with expect'
70
70
  :code: |
@@ -74,10 +74,10 @@
74
74
  POINT_T ex = {1, 2};
75
75
  bar_ExpectAndReturn(&pt);
76
76
  foo_Expect(&ex);
77
-
77
+
78
78
  function_a();
79
79
  }
80
-
80
+
81
81
  - :pass: FALSE
82
82
  :should: 'handle the situation where we pass single object with expect and it is wrong'
83
83
  :code: |
@@ -87,10 +87,10 @@
87
87
  POINT_T ex = {1, 3};
88
88
  bar_ExpectAndReturn(&pt);
89
89
  foo_Expect(&ex);
90
-
90
+
91
91
  function_a();
92
92
  }
93
-
93
+
94
94
  - :pass: FALSE
95
95
  :should: 'handle the situation where we pass nulls to pointers and fail'
96
96
  :code: |
@@ -99,10 +99,10 @@
99
99
  POINT_T pt = {1, 2};
100
100
  bar_ExpectAndReturn(&pt);
101
101
  foo_Expect(NULL);
102
-
102
+
103
103
  function_a();
104
104
  }
105
-
105
+
106
106
  - :pass: TRUE
107
107
  :should: 'handle the situation where we pass nulls to arrays'
108
108
  :code: |
@@ -110,7 +110,7 @@
110
110
  {
111
111
  bar_ExpectAndReturn(NULL);
112
112
  fooa_Expect(NULL);
113
-
113
+
114
114
  function_b();
115
115
  }
116
116
 
@@ -123,10 +123,10 @@
123
123
  POINT_T ex = {1, 2};
124
124
  bar_ExpectAndReturn(&pt);
125
125
  fooa_Expect(&ex);
126
-
126
+
127
127
  function_b();
128
128
  }
129
-
129
+
130
130
  - :pass: FALSE
131
131
  :should: 'handle the situation where we pass single array element with expect and it is wrong'
132
132
  :code: |
@@ -136,10 +136,10 @@
136
136
  POINT_T ex = {1, 3};
137
137
  bar_ExpectAndReturn(&pt);
138
138
  fooa_Expect(&ex);
139
-
139
+
140
140
  function_b();
141
141
  }
142
-
142
+
143
143
  - :pass: FALSE
144
144
  :should: 'handle the situation where we pass nulls to arrays and fail'
145
145
  :code: |
@@ -148,7 +148,7 @@
148
148
  POINT_T pt = {1, 2};
149
149
  bar_ExpectAndReturn(&pt);
150
150
  fooa_Expect(NULL);
151
-
151
+
152
152
  function_b();
153
153
  }
154
154
 
@@ -157,23 +157,25 @@
157
157
  :code: |
158
158
  test()
159
159
  {
160
- bars_ExpectAndReturn("This is a\0 silly string");
160
+ const char* retval = "This is a\0 silly string";
161
+ bars_ExpectAndReturn((char*)retval);
161
162
  foos_Expect("This is a\0 wacky string");
162
-
163
+
163
164
  function_c();
164
165
  }
165
-
166
+
166
167
  - :pass: FALSE
167
168
  :should: 'handle standard c string as null terminated on not do crappy memory compares of a byte, finding failures'
168
169
  :code: |
169
170
  test()
170
171
  {
171
- bars_ExpectAndReturn("This is a silly string");
172
+ const char* retval = "This is a silly string";
173
+ bars_ExpectAndReturn((char*)retval);
172
174
  foos_Expect("This is a wacky string");
173
-
175
+
174
176
  function_c();
175
177
  }
176
-
178
+
177
179
  - :pass: TRUE
178
180
  :should: 'handle handle typedefs that ARE pointers by using treat_as'
179
181
  :code: |
@@ -183,12 +185,12 @@
183
185
  int r = 789;
184
186
  INT_PTR ptr_e = (INT_PTR)(&e);
185
187
  INT_PTR ptr_r = (INT_PTR)(&r);
186
-
188
+
187
189
  zoink_ExpectAndReturn(ptr_e, ptr_r);
188
-
190
+
189
191
  TEST_ASSERT_EQUAL(r, function_d());
190
192
  }
191
-
193
+
192
194
  - :pass: FALSE
193
195
  :should: 'handle handle typedefs that ARE pointers by using treat_as and catch failures'
194
196
  :code: |
@@ -198,9 +200,9 @@
198
200
  int r = 789;
199
201
  INT_PTR ptr_e = (INT_PTR)(&e);
200
202
  INT_PTR ptr_r = (INT_PTR)(&r);
201
-
203
+
202
204
  zoink_ExpectAndReturn(ptr_e, ptr_r);
203
-
205
+
204
206
  TEST_ASSERT_EQUAL(r, function_d());
205
207
  }
206
208