ceedling 0.28.1 → 0.28.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/bin/ceedling +3 -2
- data/docs/CeedlingPacket.md +4 -0
- data/lib/ceedling/configurator_builder.rb +26 -0
- data/lib/ceedling/configurator_setup.rb +1 -0
- data/lib/ceedling/file_finder.rb +7 -1
- data/lib/ceedling/flaginator.rb +28 -8
- data/lib/ceedling/rules_release.rake +3 -3
- data/lib/ceedling/rules_release_deep_dependencies.rake +1 -1
- data/lib/ceedling/version.rb +3 -3
- data/plugins/gcov/config/defaults.yml +4 -3
- data/plugins/module_generator/lib/module_generator.rb +1 -1
- data/plugins/subprojects/README.md +63 -63
- data/plugins/subprojects/config/defaults.yml +33 -33
- data/plugins/subprojects/lib/subprojects.rb +92 -92
- data/plugins/subprojects/subprojects.rake +78 -78
- data/vendor/cmock/docs/CMock_Summary.md +75 -60
- data/vendor/cmock/lib/cmock_config.rb +1 -0
- data/vendor/cmock/lib/cmock_generator.rb +13 -1
- data/vendor/cmock/lib/cmock_generator_plugin_expect.rb +1 -1
- data/vendor/cmock/lib/cmock_generator_plugin_expect_any_args.rb +0 -14
- data/vendor/cmock/lib/cmock_generator_plugin_ignore.rb +4 -0
- data/vendor/cmock/lib/cmock_generator_utils.rb +4 -5
- data/vendor/cmock/lib/cmock_header_parser.rb +26 -28
- data/vendor/cmock/lib/cmock_plugin_manager.rb +27 -12
- data/vendor/cmock/scripts/create_makefile.rb +5 -4
- data/vendor/cmock/scripts/test_summary.rb +1 -1
- data/vendor/cmock/test/system/test_interactions/ignore_and_return.yml +167 -0
- data/vendor/cmock/test/system/test_interactions/ignore_strict_mock_calling.yml +37 -0
- data/vendor/cmock/test/unit/cmock_generator_main_test.rb +14 -1
- data/vendor/cmock/test/unit/cmock_generator_plugin_expect_b_test.rb +25 -24
- data/vendor/cmock/test/unit/cmock_header_parser_test.rb +101 -3
- data/vendor/unity/README.md +11 -0
- data/vendor/unity/auto/generate_module.rb +3 -3
- data/vendor/unity/auto/stylize_as_junit.rb +0 -0
- data/vendor/unity/docs/UnityAssertionsReference.md +54 -0
- data/vendor/unity/examples/unity_config.h +6 -4
- data/vendor/unity/extras/fixture/rakefile_helper.rb +1 -1
- data/vendor/unity/extras/fixture/test/Makefile +1 -0
- data/vendor/unity/src/unity.c +121 -73
- data/vendor/unity/src/unity.h +60 -0
- data/vendor/unity/src/unity_internals.h +47 -7
- data/vendor/unity/test/Makefile +1 -0
- data/vendor/unity/test/rakefile_helper.rb +1 -1
- data/vendor/unity/test/tests/testunity.c +508 -164
- metadata +3 -423
- data/out.fail +0 -21
- data/plugins/fake_function_framework/vendor/fff/LICENSE +0 -25
- data/plugins/fake_function_framework/vendor/fff/Makefile +0 -10
- data/plugins/fake_function_framework/vendor/fff/README.md +0 -454
- data/plugins/fake_function_framework/vendor/fff/buildandtest +0 -15
- data/plugins/fake_function_framework/vendor/fff/examples/Makefile +0 -7
- data/plugins/fake_function_framework/vendor/fff/examples/driver_testing/Makefile +0 -64
- data/plugins/fake_function_framework/vendor/fff/examples/driver_testing/driver.c +0 -24
- data/plugins/fake_function_framework/vendor/fff/examples/driver_testing/driver.h +0 -11
- data/plugins/fake_function_framework/vendor/fff/examples/driver_testing/driver.test.cpp +0 -50
- data/plugins/fake_function_framework/vendor/fff/examples/driver_testing/driver.test.fff.cpp +0 -62
- data/plugins/fake_function_framework/vendor/fff/examples/driver_testing/hardware_abstraction.h +0 -15
- data/plugins/fake_function_framework/vendor/fff/examples/driver_testing/registers.h +0 -13
- data/plugins/fake_function_framework/vendor/fff/examples/embedded_ui/DISPLAY.h +0 -17
- data/plugins/fake_function_framework/vendor/fff/examples/embedded_ui/Kata.txt +0 -25
- data/plugins/fake_function_framework/vendor/fff/examples/embedded_ui/Makefile +0 -67
- data/plugins/fake_function_framework/vendor/fff/examples/embedded_ui/SYSTEM.h +0 -21
- data/plugins/fake_function_framework/vendor/fff/examples/embedded_ui/UI.c +0 -48
- data/plugins/fake_function_framework/vendor/fff/examples/embedded_ui/UI.h +0 -12
- data/plugins/fake_function_framework/vendor/fff/examples/embedded_ui/UI_test_ansic.c +0 -183
- data/plugins/fake_function_framework/vendor/fff/examples/embedded_ui/UI_test_cpp.cpp +0 -136
- data/plugins/fake_function_framework/vendor/fff/examples/embedded_ui/test_suite_template.c +0 -34
- data/plugins/fake_function_framework/vendor/fff/fakegen.rb +0 -420
- data/plugins/fake_function_framework/vendor/fff/fff.h +0 -5112
- data/plugins/fake_function_framework/vendor/fff/gtest/Makefile +0 -22
- data/plugins/fake_function_framework/vendor/fff/gtest/gtest-all.cc +0 -9118
- data/plugins/fake_function_framework/vendor/fff/gtest/gtest-main.cc +0 -6
- data/plugins/fake_function_framework/vendor/fff/gtest/gtest.h +0 -19537
- data/plugins/fake_function_framework/vendor/fff/test/Makefile +0 -81
- data/plugins/fake_function_framework/vendor/fff/test/c_test_framework.h +0 -15
- data/plugins/fake_function_framework/vendor/fff/test/fff_test_c.c +0 -108
- data/plugins/fake_function_framework/vendor/fff/test/fff_test_cpp.cpp +0 -45
- data/plugins/fake_function_framework/vendor/fff/test/fff_test_global_c.c +0 -76
- data/plugins/fake_function_framework/vendor/fff/test/fff_test_global_cpp.cpp +0 -23
- data/plugins/fake_function_framework/vendor/fff/test/global_fakes.c +0 -13
- data/plugins/fake_function_framework/vendor/fff/test/global_fakes.h +0 -37
- data/plugins/fake_function_framework/vendor/fff/test/test_cases.include +0 -276
- data/vendor/c_exception/vendor/unity/README.md +0 -220
- data/vendor/c_exception/vendor/unity/auto/colour_prompt.rb +0 -118
- data/vendor/c_exception/vendor/unity/auto/colour_reporter.rb +0 -39
- data/vendor/c_exception/vendor/unity/auto/generate_config.yml +0 -36
- data/vendor/c_exception/vendor/unity/auto/generate_module.rb +0 -308
- data/vendor/c_exception/vendor/unity/auto/generate_test_runner.rb +0 -437
- data/vendor/c_exception/vendor/unity/auto/parse_output.rb +0 -220
- data/vendor/c_exception/vendor/unity/auto/stylize_as_junit.rb +0 -252
- data/vendor/c_exception/vendor/unity/auto/test_file_filter.rb +0 -25
- data/vendor/c_exception/vendor/unity/auto/type_sanitizer.rb +0 -6
- data/vendor/c_exception/vendor/unity/auto/unity_test_summary.py +0 -139
- data/vendor/c_exception/vendor/unity/auto/unity_test_summary.rb +0 -136
- data/vendor/c_exception/vendor/unity/auto/unity_to_junit.py +0 -146
- data/vendor/c_exception/vendor/unity/docs/ThrowTheSwitchCodingStandard.md +0 -207
- data/vendor/c_exception/vendor/unity/docs/UnityAssertionsCheatSheetSuitableforPrintingandPossiblyFraming.pdf +0 -0
- data/vendor/c_exception/vendor/unity/docs/UnityAssertionsReference.md +0 -716
- data/vendor/c_exception/vendor/unity/docs/UnityConfigurationGuide.md +0 -398
- data/vendor/c_exception/vendor/unity/docs/UnityGettingStartedGuide.md +0 -191
- data/vendor/c_exception/vendor/unity/docs/UnityHelperScriptsGuide.md +0 -242
- data/vendor/c_exception/vendor/unity/docs/license.txt +0 -21
- data/vendor/c_exception/vendor/unity/examples/example_1/makefile +0 -71
- data/vendor/c_exception/vendor/unity/examples/example_1/readme.txt +0 -5
- data/vendor/c_exception/vendor/unity/examples/example_1/src/ProductionCode.c +0 -24
- data/vendor/c_exception/vendor/unity/examples/example_1/src/ProductionCode.h +0 -3
- data/vendor/c_exception/vendor/unity/examples/example_1/src/ProductionCode2.c +0 -11
- data/vendor/c_exception/vendor/unity/examples/example_1/src/ProductionCode2.h +0 -2
- data/vendor/c_exception/vendor/unity/examples/example_1/test/TestProductionCode.c +0 -62
- data/vendor/c_exception/vendor/unity/examples/example_1/test/TestProductionCode2.c +0 -31
- data/vendor/c_exception/vendor/unity/examples/example_1/test/test_runners/TestProductionCode2_Runner.c +0 -53
- data/vendor/c_exception/vendor/unity/examples/example_1/test/test_runners/TestProductionCode_Runner.c +0 -57
- data/vendor/c_exception/vendor/unity/examples/example_2/makefile +0 -70
- data/vendor/c_exception/vendor/unity/examples/example_2/readme.txt +0 -5
- data/vendor/c_exception/vendor/unity/examples/example_2/src/ProductionCode.c +0 -24
- data/vendor/c_exception/vendor/unity/examples/example_2/src/ProductionCode.h +0 -3
- data/vendor/c_exception/vendor/unity/examples/example_2/src/ProductionCode2.c +0 -11
- data/vendor/c_exception/vendor/unity/examples/example_2/src/ProductionCode2.h +0 -2
- data/vendor/c_exception/vendor/unity/examples/example_2/test/TestProductionCode.c +0 -64
- data/vendor/c_exception/vendor/unity/examples/example_2/test/TestProductionCode2.c +0 -33
- data/vendor/c_exception/vendor/unity/examples/example_2/test/test_runners/TestProductionCode2_Runner.c +0 -9
- data/vendor/c_exception/vendor/unity/examples/example_2/test/test_runners/TestProductionCode_Runner.c +0 -11
- data/vendor/c_exception/vendor/unity/examples/example_2/test/test_runners/all_tests.c +0 -12
- data/vendor/c_exception/vendor/unity/examples/example_3/helper/UnityHelper.c +0 -10
- data/vendor/c_exception/vendor/unity/examples/example_3/helper/UnityHelper.h +0 -12
- data/vendor/c_exception/vendor/unity/examples/example_3/rakefile.rb +0 -43
- data/vendor/c_exception/vendor/unity/examples/example_3/rakefile_helper.rb +0 -249
- data/vendor/c_exception/vendor/unity/examples/example_3/readme.txt +0 -13
- data/vendor/c_exception/vendor/unity/examples/example_3/src/ProductionCode.c +0 -24
- data/vendor/c_exception/vendor/unity/examples/example_3/src/ProductionCode.h +0 -3
- data/vendor/c_exception/vendor/unity/examples/example_3/src/ProductionCode2.c +0 -11
- data/vendor/c_exception/vendor/unity/examples/example_3/src/ProductionCode2.h +0 -2
- data/vendor/c_exception/vendor/unity/examples/example_3/target_gcc_32.yml +0 -46
- data/vendor/c_exception/vendor/unity/examples/example_3/test/TestProductionCode.c +0 -62
- data/vendor/c_exception/vendor/unity/examples/example_3/test/TestProductionCode2.c +0 -31
- data/vendor/c_exception/vendor/unity/examples/unity_config.h +0 -237
- data/vendor/c_exception/vendor/unity/extras/eclipse/error_parsers.txt +0 -26
- data/vendor/c_exception/vendor/unity/extras/fixture/rakefile.rb +0 -48
- data/vendor/c_exception/vendor/unity/extras/fixture/rakefile_helper.rb +0 -178
- data/vendor/c_exception/vendor/unity/extras/fixture/readme.txt +0 -9
- data/vendor/c_exception/vendor/unity/extras/fixture/src/unity_fixture.c +0 -432
- data/vendor/c_exception/vendor/unity/extras/fixture/src/unity_fixture.h +0 -83
- data/vendor/c_exception/vendor/unity/extras/fixture/src/unity_fixture_internals.h +0 -51
- data/vendor/c_exception/vendor/unity/extras/fixture/src/unity_fixture_malloc_overrides.h +0 -47
- data/vendor/c_exception/vendor/unity/extras/fixture/test/Makefile +0 -74
- data/vendor/c_exception/vendor/unity/extras/fixture/test/main/AllTests.c +0 -22
- data/vendor/c_exception/vendor/unity/extras/fixture/test/template_fixture_tests.c +0 -39
- data/vendor/c_exception/vendor/unity/extras/fixture/test/unity_fixture_Test.c +0 -543
- data/vendor/c_exception/vendor/unity/extras/fixture/test/unity_fixture_TestRunner.c +0 -57
- data/vendor/c_exception/vendor/unity/extras/fixture/test/unity_output_Spy.c +0 -57
- data/vendor/c_exception/vendor/unity/extras/fixture/test/unity_output_Spy.h +0 -17
- data/vendor/c_exception/vendor/unity/release/build.info +0 -2
- data/vendor/c_exception/vendor/unity/release/version.info +0 -2
- data/vendor/c_exception/vendor/unity/src/unity.c +0 -1517
- data/vendor/c_exception/vendor/unity/src/unity.h +0 -339
- data/vendor/c_exception/vendor/unity/src/unity_internals.h +0 -784
- data/vendor/c_exception/vendor/unity/test/Makefile +0 -63
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_cmd.c +0 -61
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_def.c +0 -57
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_head1.c +0 -55
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_head1.h +0 -15
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_cmd.c +0 -80
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_def.c +0 -76
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_head1.c +0 -75
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_head1.h +0 -13
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_new1.c +0 -89
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_new2.c +0 -89
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_param.c +0 -77
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_run1.c +0 -89
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_run2.c +0 -89
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_yaml.c +0 -90
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_new1.c +0 -67
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_new2.c +0 -70
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_param.c +0 -58
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_run1.c +0 -67
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_run2.c +0 -70
- data/vendor/c_exception/vendor/unity/test/expectdata/testsample_yaml.c +0 -71
- data/vendor/c_exception/vendor/unity/test/rakefile +0 -125
- data/vendor/c_exception/vendor/unity/test/rakefile_helper.rb +0 -260
- data/vendor/c_exception/vendor/unity/test/spec/generate_module_existing_file_spec.rb +0 -158
- data/vendor/c_exception/vendor/unity/test/targets/clang_file.yml +0 -78
- data/vendor/c_exception/vendor/unity/test/targets/clang_strict.yml +0 -78
- data/vendor/c_exception/vendor/unity/test/targets/gcc_32.yml +0 -49
- data/vendor/c_exception/vendor/unity/test/targets/gcc_64.yml +0 -50
- data/vendor/c_exception/vendor/unity/test/targets/gcc_auto_limits.yml +0 -47
- data/vendor/c_exception/vendor/unity/test/targets/gcc_auto_stdint.yml +0 -59
- data/vendor/c_exception/vendor/unity/test/targets/gcc_manual_math.yml +0 -47
- data/vendor/c_exception/vendor/unity/test/targets/hitech_picc18.yml +0 -101
- data/vendor/c_exception/vendor/unity/test/targets/iar_arm_v4.yml +0 -90
- data/vendor/c_exception/vendor/unity/test/targets/iar_arm_v5.yml +0 -80
- data/vendor/c_exception/vendor/unity/test/targets/iar_arm_v5_3.yml +0 -80
- data/vendor/c_exception/vendor/unity/test/targets/iar_armcortex_LM3S9B92_v5_4.yml +0 -94
- data/vendor/c_exception/vendor/unity/test/targets/iar_cortexm3_v5.yml +0 -84
- data/vendor/c_exception/vendor/unity/test/targets/iar_msp430.yml +0 -95
- data/vendor/c_exception/vendor/unity/test/targets/iar_sh2a_v6.yml +0 -86
- data/vendor/c_exception/vendor/unity/test/testdata/CException.h +0 -11
- data/vendor/c_exception/vendor/unity/test/testdata/Defs.h +0 -8
- data/vendor/c_exception/vendor/unity/test/testdata/cmock.h +0 -14
- data/vendor/c_exception/vendor/unity/test/testdata/mockMock.h +0 -13
- data/vendor/c_exception/vendor/unity/test/testdata/testRunnerGenerator.c +0 -183
- data/vendor/c_exception/vendor/unity/test/testdata/testRunnerGeneratorSmall.c +0 -67
- data/vendor/c_exception/vendor/unity/test/testdata/testRunnerGeneratorWithMocks.c +0 -192
- data/vendor/c_exception/vendor/unity/test/tests/test_generate_test_runner.rb +0 -1252
- data/vendor/c_exception/vendor/unity/test/tests/testparameterized.c +0 -110
- data/vendor/c_exception/vendor/unity/test/tests/testunity.c +0 -4993
- data/vendor/cmock/vendor/c_exception/Gemfile +0 -4
- data/vendor/cmock/vendor/c_exception/Gemfile.lock +0 -12
- data/vendor/cmock/vendor/c_exception/LICENSE.txt +0 -30
- data/vendor/cmock/vendor/c_exception/README.md +0 -162
- data/vendor/cmock/vendor/c_exception/Rakefile +0 -42
- data/vendor/cmock/vendor/c_exception/docs/CException.md +0 -292
- data/vendor/cmock/vendor/c_exception/docs/ThrowTheSwitchCodingStandard.md +0 -207
- data/vendor/cmock/vendor/c_exception/lib/CException.c +0 -46
- data/vendor/cmock/vendor/c_exception/lib/CException.h +0 -110
- data/vendor/cmock/vendor/c_exception/makefile +0 -24
- data/vendor/cmock/vendor/c_exception/release/build.info +0 -2
- data/vendor/cmock/vendor/c_exception/release/version.info +0 -2
- data/vendor/cmock/vendor/c_exception/test/CExceptionConfig.h +0 -46
- data/vendor/cmock/vendor/c_exception/test/TestException.c +0 -391
- data/vendor/cmock/vendor/c_exception/test/TestException_Runner.c +0 -67
- data/vendor/cmock/vendor/c_exception/vendor/unity/README.md +0 -220
- data/vendor/cmock/vendor/c_exception/vendor/unity/auto/colour_prompt.rb +0 -118
- data/vendor/cmock/vendor/c_exception/vendor/unity/auto/colour_reporter.rb +0 -39
- data/vendor/cmock/vendor/c_exception/vendor/unity/auto/generate_config.yml +0 -36
- data/vendor/cmock/vendor/c_exception/vendor/unity/auto/generate_module.rb +0 -308
- data/vendor/cmock/vendor/c_exception/vendor/unity/auto/generate_test_runner.rb +0 -437
- data/vendor/cmock/vendor/c_exception/vendor/unity/auto/parse_output.rb +0 -220
- data/vendor/cmock/vendor/c_exception/vendor/unity/auto/stylize_as_junit.rb +0 -252
- data/vendor/cmock/vendor/c_exception/vendor/unity/auto/test_file_filter.rb +0 -25
- data/vendor/cmock/vendor/c_exception/vendor/unity/auto/type_sanitizer.rb +0 -6
- data/vendor/cmock/vendor/c_exception/vendor/unity/auto/unity_test_summary.py +0 -139
- data/vendor/cmock/vendor/c_exception/vendor/unity/auto/unity_test_summary.rb +0 -136
- data/vendor/cmock/vendor/c_exception/vendor/unity/auto/unity_to_junit.py +0 -146
- data/vendor/cmock/vendor/c_exception/vendor/unity/docs/ThrowTheSwitchCodingStandard.md +0 -207
- data/vendor/cmock/vendor/c_exception/vendor/unity/docs/UnityAssertionsCheatSheetSuitableforPrintingandPossiblyFraming.pdf +0 -0
- data/vendor/cmock/vendor/c_exception/vendor/unity/docs/UnityAssertionsReference.md +0 -716
- data/vendor/cmock/vendor/c_exception/vendor/unity/docs/UnityConfigurationGuide.md +0 -398
- data/vendor/cmock/vendor/c_exception/vendor/unity/docs/UnityGettingStartedGuide.md +0 -191
- data/vendor/cmock/vendor/c_exception/vendor/unity/docs/UnityHelperScriptsGuide.md +0 -242
- data/vendor/cmock/vendor/c_exception/vendor/unity/docs/license.txt +0 -21
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_1/makefile +0 -71
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_1/readme.txt +0 -5
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_1/src/ProductionCode.c +0 -24
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_1/src/ProductionCode.h +0 -3
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_1/src/ProductionCode2.c +0 -11
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_1/src/ProductionCode2.h +0 -2
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_1/test/TestProductionCode.c +0 -62
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_1/test/TestProductionCode2.c +0 -31
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_1/test/test_runners/TestProductionCode2_Runner.c +0 -53
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_1/test/test_runners/TestProductionCode_Runner.c +0 -57
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_2/makefile +0 -70
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_2/readme.txt +0 -5
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_2/src/ProductionCode.c +0 -24
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_2/src/ProductionCode.h +0 -3
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_2/src/ProductionCode2.c +0 -11
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_2/src/ProductionCode2.h +0 -2
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_2/test/TestProductionCode.c +0 -64
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_2/test/TestProductionCode2.c +0 -33
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_2/test/test_runners/TestProductionCode2_Runner.c +0 -9
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_2/test/test_runners/TestProductionCode_Runner.c +0 -11
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_2/test/test_runners/all_tests.c +0 -12
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_3/helper/UnityHelper.c +0 -10
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_3/helper/UnityHelper.h +0 -12
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_3/rakefile.rb +0 -43
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_3/rakefile_helper.rb +0 -249
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_3/readme.txt +0 -13
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_3/src/ProductionCode.c +0 -24
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_3/src/ProductionCode.h +0 -3
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_3/src/ProductionCode2.c +0 -11
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_3/src/ProductionCode2.h +0 -2
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_3/target_gcc_32.yml +0 -46
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_3/test/TestProductionCode.c +0 -62
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/example_3/test/TestProductionCode2.c +0 -31
- data/vendor/cmock/vendor/c_exception/vendor/unity/examples/unity_config.h +0 -237
- data/vendor/cmock/vendor/c_exception/vendor/unity/extras/eclipse/error_parsers.txt +0 -26
- data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/rakefile.rb +0 -48
- data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/rakefile_helper.rb +0 -178
- data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/readme.txt +0 -9
- data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/src/unity_fixture.c +0 -432
- data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/src/unity_fixture.h +0 -83
- data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/src/unity_fixture_internals.h +0 -51
- data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/src/unity_fixture_malloc_overrides.h +0 -47
- data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/test/Makefile +0 -74
- data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/test/main/AllTests.c +0 -22
- data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/test/template_fixture_tests.c +0 -39
- data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/test/unity_fixture_Test.c +0 -543
- data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/test/unity_fixture_TestRunner.c +0 -57
- data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/test/unity_output_Spy.c +0 -57
- data/vendor/cmock/vendor/c_exception/vendor/unity/extras/fixture/test/unity_output_Spy.h +0 -17
- data/vendor/cmock/vendor/c_exception/vendor/unity/release/build.info +0 -2
- data/vendor/cmock/vendor/c_exception/vendor/unity/release/version.info +0 -2
- data/vendor/cmock/vendor/c_exception/vendor/unity/src/unity.c +0 -1517
- data/vendor/cmock/vendor/c_exception/vendor/unity/src/unity.h +0 -339
- data/vendor/cmock/vendor/c_exception/vendor/unity/src/unity_internals.h +0 -784
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/Makefile +0 -63
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_cmd.c +0 -61
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_def.c +0 -57
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_head1.c +0 -55
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_head1.h +0 -15
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_cmd.c +0 -80
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_def.c +0 -76
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_head1.c +0 -75
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_head1.h +0 -13
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_new1.c +0 -89
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_new2.c +0 -89
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_param.c +0 -77
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_run1.c +0 -89
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_run2.c +0 -89
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_mock_yaml.c +0 -90
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_new1.c +0 -67
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_new2.c +0 -70
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_param.c +0 -58
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_run1.c +0 -67
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_run2.c +0 -70
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/expectdata/testsample_yaml.c +0 -71
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/rakefile +0 -125
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/rakefile_helper.rb +0 -260
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/spec/generate_module_existing_file_spec.rb +0 -158
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/clang_file.yml +0 -78
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/clang_strict.yml +0 -78
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/gcc_32.yml +0 -49
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/gcc_64.yml +0 -50
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/gcc_auto_limits.yml +0 -47
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/gcc_auto_stdint.yml +0 -59
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/gcc_manual_math.yml +0 -47
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/hitech_picc18.yml +0 -101
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/iar_arm_v4.yml +0 -90
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/iar_arm_v5.yml +0 -80
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/iar_arm_v5_3.yml +0 -80
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/iar_armcortex_LM3S9B92_v5_4.yml +0 -94
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/iar_cortexm3_v5.yml +0 -84
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/iar_msp430.yml +0 -95
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/targets/iar_sh2a_v6.yml +0 -86
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/testdata/CException.h +0 -11
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/testdata/Defs.h +0 -8
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/testdata/cmock.h +0 -14
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/testdata/mockMock.h +0 -13
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/testdata/testRunnerGenerator.c +0 -183
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/testdata/testRunnerGeneratorSmall.c +0 -67
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/testdata/testRunnerGeneratorWithMocks.c +0 -192
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/tests/test_generate_test_runner.rb +0 -1252
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/tests/testparameterized.c +0 -110
- data/vendor/cmock/vendor/c_exception/vendor/unity/test/tests/testunity.c +0 -4993
- data/vendor/cmock/vendor/unity/README.md +0 -220
- data/vendor/cmock/vendor/unity/auto/colour_prompt.rb +0 -118
- data/vendor/cmock/vendor/unity/auto/colour_reporter.rb +0 -39
- data/vendor/cmock/vendor/unity/auto/generate_config.yml +0 -36
- data/vendor/cmock/vendor/unity/auto/generate_module.rb +0 -308
- data/vendor/cmock/vendor/unity/auto/generate_test_runner.rb +0 -437
- data/vendor/cmock/vendor/unity/auto/parse_output.rb +0 -220
- data/vendor/cmock/vendor/unity/auto/stylize_as_junit.rb +0 -252
- data/vendor/cmock/vendor/unity/auto/test_file_filter.rb +0 -25
- data/vendor/cmock/vendor/unity/auto/type_sanitizer.rb +0 -6
- data/vendor/cmock/vendor/unity/auto/unity_test_summary.py +0 -139
- data/vendor/cmock/vendor/unity/auto/unity_test_summary.rb +0 -136
- data/vendor/cmock/vendor/unity/auto/unity_to_junit.py +0 -146
- data/vendor/cmock/vendor/unity/docs/ThrowTheSwitchCodingStandard.md +0 -207
- data/vendor/cmock/vendor/unity/docs/UnityAssertionsCheatSheetSuitableforPrintingandPossiblyFraming.pdf +0 -0
- data/vendor/cmock/vendor/unity/docs/UnityAssertionsReference.md +0 -716
- data/vendor/cmock/vendor/unity/docs/UnityConfigurationGuide.md +0 -398
- data/vendor/cmock/vendor/unity/docs/UnityGettingStartedGuide.md +0 -191
- data/vendor/cmock/vendor/unity/docs/UnityHelperScriptsGuide.md +0 -242
- data/vendor/cmock/vendor/unity/docs/license.txt +0 -21
- data/vendor/cmock/vendor/unity/examples/example_1/makefile +0 -71
- data/vendor/cmock/vendor/unity/examples/example_1/readme.txt +0 -5
- data/vendor/cmock/vendor/unity/examples/example_1/src/ProductionCode.c +0 -24
- data/vendor/cmock/vendor/unity/examples/example_1/src/ProductionCode.h +0 -3
- data/vendor/cmock/vendor/unity/examples/example_1/src/ProductionCode2.c +0 -11
- data/vendor/cmock/vendor/unity/examples/example_1/src/ProductionCode2.h +0 -2
- data/vendor/cmock/vendor/unity/examples/example_1/test/TestProductionCode.c +0 -62
- data/vendor/cmock/vendor/unity/examples/example_1/test/TestProductionCode2.c +0 -31
- data/vendor/cmock/vendor/unity/examples/example_1/test/test_runners/TestProductionCode2_Runner.c +0 -53
- data/vendor/cmock/vendor/unity/examples/example_1/test/test_runners/TestProductionCode_Runner.c +0 -57
- data/vendor/cmock/vendor/unity/examples/example_2/makefile +0 -70
- data/vendor/cmock/vendor/unity/examples/example_2/readme.txt +0 -5
- data/vendor/cmock/vendor/unity/examples/example_2/src/ProductionCode.c +0 -24
- data/vendor/cmock/vendor/unity/examples/example_2/src/ProductionCode.h +0 -3
- data/vendor/cmock/vendor/unity/examples/example_2/src/ProductionCode2.c +0 -11
- data/vendor/cmock/vendor/unity/examples/example_2/src/ProductionCode2.h +0 -2
- data/vendor/cmock/vendor/unity/examples/example_2/test/TestProductionCode.c +0 -64
- data/vendor/cmock/vendor/unity/examples/example_2/test/TestProductionCode2.c +0 -33
- data/vendor/cmock/vendor/unity/examples/example_2/test/test_runners/TestProductionCode2_Runner.c +0 -9
- data/vendor/cmock/vendor/unity/examples/example_2/test/test_runners/TestProductionCode_Runner.c +0 -11
- data/vendor/cmock/vendor/unity/examples/example_2/test/test_runners/all_tests.c +0 -12
- data/vendor/cmock/vendor/unity/examples/example_3/helper/UnityHelper.c +0 -10
- data/vendor/cmock/vendor/unity/examples/example_3/helper/UnityHelper.h +0 -12
- data/vendor/cmock/vendor/unity/examples/example_3/rakefile.rb +0 -43
- data/vendor/cmock/vendor/unity/examples/example_3/rakefile_helper.rb +0 -249
- data/vendor/cmock/vendor/unity/examples/example_3/readme.txt +0 -13
- data/vendor/cmock/vendor/unity/examples/example_3/src/ProductionCode.c +0 -24
- data/vendor/cmock/vendor/unity/examples/example_3/src/ProductionCode.h +0 -3
- data/vendor/cmock/vendor/unity/examples/example_3/src/ProductionCode2.c +0 -11
- data/vendor/cmock/vendor/unity/examples/example_3/src/ProductionCode2.h +0 -2
- data/vendor/cmock/vendor/unity/examples/example_3/target_gcc_32.yml +0 -46
- data/vendor/cmock/vendor/unity/examples/example_3/test/TestProductionCode.c +0 -62
- data/vendor/cmock/vendor/unity/examples/example_3/test/TestProductionCode2.c +0 -31
- data/vendor/cmock/vendor/unity/examples/unity_config.h +0 -237
- data/vendor/cmock/vendor/unity/extras/eclipse/error_parsers.txt +0 -26
- data/vendor/cmock/vendor/unity/extras/fixture/rakefile.rb +0 -48
- data/vendor/cmock/vendor/unity/extras/fixture/rakefile_helper.rb +0 -178
- data/vendor/cmock/vendor/unity/extras/fixture/readme.txt +0 -9
- data/vendor/cmock/vendor/unity/extras/fixture/src/unity_fixture.c +0 -432
- data/vendor/cmock/vendor/unity/extras/fixture/src/unity_fixture.h +0 -83
- data/vendor/cmock/vendor/unity/extras/fixture/src/unity_fixture_internals.h +0 -51
- data/vendor/cmock/vendor/unity/extras/fixture/src/unity_fixture_malloc_overrides.h +0 -47
- data/vendor/cmock/vendor/unity/extras/fixture/test/Makefile +0 -74
- data/vendor/cmock/vendor/unity/extras/fixture/test/main/AllTests.c +0 -22
- data/vendor/cmock/vendor/unity/extras/fixture/test/template_fixture_tests.c +0 -39
- data/vendor/cmock/vendor/unity/extras/fixture/test/unity_fixture_Test.c +0 -543
- data/vendor/cmock/vendor/unity/extras/fixture/test/unity_fixture_TestRunner.c +0 -57
- data/vendor/cmock/vendor/unity/extras/fixture/test/unity_output_Spy.c +0 -57
- data/vendor/cmock/vendor/unity/extras/fixture/test/unity_output_Spy.h +0 -17
- data/vendor/cmock/vendor/unity/release/build.info +0 -2
- data/vendor/cmock/vendor/unity/release/version.info +0 -2
- data/vendor/cmock/vendor/unity/src/unity.c +0 -1517
- data/vendor/cmock/vendor/unity/src/unity.h +0 -339
- data/vendor/cmock/vendor/unity/src/unity_internals.h +0 -784
- data/vendor/cmock/vendor/unity/test/Makefile +0 -63
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_cmd.c +0 -61
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_def.c +0 -57
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_head1.c +0 -55
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_head1.h +0 -15
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_cmd.c +0 -80
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_def.c +0 -76
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_head1.c +0 -75
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_head1.h +0 -13
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_new1.c +0 -89
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_new2.c +0 -89
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_param.c +0 -77
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_run1.c +0 -89
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_run2.c +0 -89
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_mock_yaml.c +0 -90
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_new1.c +0 -67
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_new2.c +0 -70
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_param.c +0 -58
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_run1.c +0 -67
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_run2.c +0 -70
- data/vendor/cmock/vendor/unity/test/expectdata/testsample_yaml.c +0 -71
- data/vendor/cmock/vendor/unity/test/rakefile +0 -125
- data/vendor/cmock/vendor/unity/test/rakefile_helper.rb +0 -260
- data/vendor/cmock/vendor/unity/test/spec/generate_module_existing_file_spec.rb +0 -158
- data/vendor/cmock/vendor/unity/test/targets/clang_file.yml +0 -78
- data/vendor/cmock/vendor/unity/test/targets/clang_strict.yml +0 -78
- data/vendor/cmock/vendor/unity/test/targets/gcc_32.yml +0 -49
- data/vendor/cmock/vendor/unity/test/targets/gcc_64.yml +0 -50
- data/vendor/cmock/vendor/unity/test/targets/gcc_auto_limits.yml +0 -47
- data/vendor/cmock/vendor/unity/test/targets/gcc_auto_stdint.yml +0 -59
- data/vendor/cmock/vendor/unity/test/targets/gcc_manual_math.yml +0 -47
- data/vendor/cmock/vendor/unity/test/targets/hitech_picc18.yml +0 -101
- data/vendor/cmock/vendor/unity/test/targets/iar_arm_v4.yml +0 -90
- data/vendor/cmock/vendor/unity/test/targets/iar_arm_v5.yml +0 -80
- data/vendor/cmock/vendor/unity/test/targets/iar_arm_v5_3.yml +0 -80
- data/vendor/cmock/vendor/unity/test/targets/iar_armcortex_LM3S9B92_v5_4.yml +0 -94
- data/vendor/cmock/vendor/unity/test/targets/iar_cortexm3_v5.yml +0 -84
- data/vendor/cmock/vendor/unity/test/targets/iar_msp430.yml +0 -95
- data/vendor/cmock/vendor/unity/test/targets/iar_sh2a_v6.yml +0 -86
- data/vendor/cmock/vendor/unity/test/testdata/CException.h +0 -11
- data/vendor/cmock/vendor/unity/test/testdata/Defs.h +0 -8
- data/vendor/cmock/vendor/unity/test/testdata/cmock.h +0 -14
- data/vendor/cmock/vendor/unity/test/testdata/mockMock.h +0 -13
- data/vendor/cmock/vendor/unity/test/testdata/testRunnerGenerator.c +0 -183
- data/vendor/cmock/vendor/unity/test/testdata/testRunnerGeneratorSmall.c +0 -67
- data/vendor/cmock/vendor/unity/test/testdata/testRunnerGeneratorWithMocks.c +0 -192
- data/vendor/cmock/vendor/unity/test/tests/test_generate_test_runner.rb +0 -1252
- data/vendor/cmock/vendor/unity/test/tests/testparameterized.c +0 -110
- data/vendor/cmock/vendor/unity/test/tests/testunity.c +0 -4993
data/out.fail
DELETED
@@ -1,21 +0,0 @@
|
|
1
|
-
---
|
2
|
-
:source:
|
3
|
-
:path: some/place
|
4
|
-
:file: test_example.c
|
5
|
-
:successes: []
|
6
|
-
:failures:
|
7
|
-
- :test: test_one
|
8
|
-
:line: 257
|
9
|
-
:message: ''
|
10
|
-
- :test: test_two
|
11
|
-
:line: 269
|
12
|
-
:message: ''
|
13
|
-
:ignores: []
|
14
|
-
:counts:
|
15
|
-
:total: 2
|
16
|
-
:passed: 0
|
17
|
-
:failed: 2
|
18
|
-
:ignored: 0
|
19
|
-
:stdout:
|
20
|
-
- Verbose output one
|
21
|
-
- Verbous output two
|
@@ -1,25 +0,0 @@
|
|
1
|
-
/*
|
2
|
-
LICENSE
|
3
|
-
|
4
|
-
The MIT License (MIT)
|
5
|
-
|
6
|
-
Copyright (c) 2010 Michael Long
|
7
|
-
|
8
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
9
|
-
of this software and associated documentation files (the "Software"), to deal
|
10
|
-
in the Software without restriction, including without limitation the rights
|
11
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
12
|
-
copies of the Software, and to permit persons to whom the Software is
|
13
|
-
furnished to do so, subject to the following conditions:
|
14
|
-
|
15
|
-
The above copyright notice and this permission notice shall be included in all
|
16
|
-
copies or substantial portions of the Software.
|
17
|
-
|
18
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
19
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
20
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
21
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
22
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
23
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
24
|
-
SOFTWARE.
|
25
|
-
*/
|
@@ -1,454 +0,0 @@
|
|
1
|
-
# Fake Function Framework (fff)
|
2
|
-
-----------------------------
|
3
|
-
> How long can we _maintain_? I wonder. How long before one of us starts raving
|
4
|
-
> and jabbering at this boy? What will he think then? This same lonely desert
|
5
|
-
> was the last known home of the Manson family. Will he make that grim
|
6
|
-
> connection...
|
7
|
-
|
8
|
-
## A Fake Function Framework for C
|
9
|
-
fff is a micro-framework for creating fake C functions for tests. Because life
|
10
|
-
is too short to spend time hand-writing fake functions for testing.
|
11
|
-
|
12
|
-
|
13
|
-
## Hello fake world!
|
14
|
-
|
15
|
-
Say you are testing an embedded user interface and you have a function that
|
16
|
-
you want to create a fake for:
|
17
|
-
|
18
|
-
// UI.c
|
19
|
-
...
|
20
|
-
void DISPLAY_init();
|
21
|
-
...
|
22
|
-
|
23
|
-
Here's how you would define a fake function for this in your test suite:
|
24
|
-
|
25
|
-
// test.c(pp)
|
26
|
-
#include "fff.h"
|
27
|
-
DEFINE_FFF_GLOBALS;
|
28
|
-
FAKE_VOID_FUNC(DISPLAY_init);
|
29
|
-
|
30
|
-
And the unit test might look something like this:
|
31
|
-
|
32
|
-
TEST_F(GreeterTests, init_initialises_display)
|
33
|
-
{
|
34
|
-
UI_init();
|
35
|
-
ASSERT_EQ(DISPLAY_init_fake.call_count, 1);
|
36
|
-
}
|
37
|
-
|
38
|
-
So what has happened here? The first thing to note is that the framework is
|
39
|
-
header only, all you need to do to use it is download <tt>fff.h</tt> and include
|
40
|
-
it in your test suite.
|
41
|
-
|
42
|
-
The magic is in the <tt>FAKE_VOID_FUNC</tt>. This
|
43
|
-
expands a macro that defines a function returning <tt>void</tt>
|
44
|
-
which has zero arguments. It also defines a struct
|
45
|
-
<tt>"function_name"_fake</tt> which contains all the information about the fake.
|
46
|
-
For instance, <tt>DISPLAY_init_fake.call_count</tt>is incremented every time the faked
|
47
|
-
function is called.
|
48
|
-
|
49
|
-
Under the hood it generates a struct that looks like this:
|
50
|
-
|
51
|
-
typedef struct DISPLAY_init_Fake {
|
52
|
-
unsigned int call_count;
|
53
|
-
unsigned int arg_history_len;
|
54
|
-
unsigned int arg_histories_dropped;
|
55
|
-
void(*custom_fake)();
|
56
|
-
} DISPLAY_init_Fake;
|
57
|
-
DISPLAY_init_Fake DISPLAY_init_fake;
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
## Capturing arguments
|
64
|
-
|
65
|
-
Ok, enough with the toy examples. What about faking functions with arguments?
|
66
|
-
|
67
|
-
// UI.c
|
68
|
-
...
|
69
|
-
void DISPLAY_output(char * message);
|
70
|
-
...
|
71
|
-
|
72
|
-
Here's how you would define a fake function for this in your test suite:
|
73
|
-
|
74
|
-
FAKE_VOID_FUNC(DISPLAY_output, char *);
|
75
|
-
|
76
|
-
And the unit test might look something like this:
|
77
|
-
|
78
|
-
TEST_F(UITests, write_line_outputs_lines_to_display)
|
79
|
-
{
|
80
|
-
char msg[] = "helloworld";
|
81
|
-
UI_write_line(msg);
|
82
|
-
ASSERT_EQ(DISPLAY_output_fake.call_count, 1);
|
83
|
-
ASSERT_EQ(strncmp(DISPLAY_output_fake.arg0_val, msg, 26), 0);
|
84
|
-
}
|
85
|
-
|
86
|
-
|
87
|
-
There is no more magic here, the <tt>FAKE_VOID_FUNC</tt> works as in the
|
88
|
-
previous example. The number of arguments that the function takes is calculated,
|
89
|
-
and the macro arguments following the function name defines the argument
|
90
|
-
type (a char pointer in this example).
|
91
|
-
|
92
|
-
A variable is created for every argument in the form
|
93
|
-
<tt>"function_name"fake.argN_val</tt>
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
## Return values
|
98
|
-
|
99
|
-
When you want to define a fake function that returns a value, you should use the
|
100
|
-
<tt>FAKE_VALUE_FUNC</tt> macro. For instance:
|
101
|
-
|
102
|
-
// UI.c
|
103
|
-
...
|
104
|
-
unsigned int DISPLAY_get_line_capacity();
|
105
|
-
unsigned int DISPLAY_get_line_insert_index();
|
106
|
-
...
|
107
|
-
|
108
|
-
Here's how you would define fake functions for these in your test suite:
|
109
|
-
|
110
|
-
FAKE_VALUE_FUNC(unsigned int, DISPLAY_get_line_capacity);
|
111
|
-
FAKE_VALUE_FUNC(unsigned int, DISPLAY_get_line_insert_index);
|
112
|
-
|
113
|
-
And the unit test might look something like this:
|
114
|
-
|
115
|
-
TEST_F(UITests, when_empty_lines_write_line_doesnt_clear_screen)
|
116
|
-
{
|
117
|
-
// given
|
118
|
-
DISPLAY_get_line_insert_index_fake.return_val = 1;
|
119
|
-
char msg[] = "helloworld";
|
120
|
-
// when
|
121
|
-
UI_write_line(msg);
|
122
|
-
// then
|
123
|
-
ASSERT_EQ(DISPLAY_clear_fake.call_count, 0);
|
124
|
-
}
|
125
|
-
|
126
|
-
Of course you can mix and match these macros to define a value function with
|
127
|
-
arguments, for instance to fake:
|
128
|
-
|
129
|
-
double pow(double base, double exponent);
|
130
|
-
|
131
|
-
you would use a syntax like this:
|
132
|
-
|
133
|
-
FAKE_VALUE_FUNC(double, pow, double, double);
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
## Resetting a fake
|
138
|
-
|
139
|
-
Good tests are isolated tests, so it is important to reset the fakes for each
|
140
|
-
unit test. All the fakes have a reset function to reset their arguments and
|
141
|
-
call counts. It is good prectice is to call the reset function for all the
|
142
|
-
fakes in the setup function of your test suite.
|
143
|
-
|
144
|
-
void setup()
|
145
|
-
{
|
146
|
-
// Register resets
|
147
|
-
RESET_FAKE(DISPLAY_init);
|
148
|
-
RESET_FAKE(DISPLAY_clear);
|
149
|
-
RESET_FAKE(DISPLAY_output_message);
|
150
|
-
RESET_FAKE(DISPLAY_get_line_capacity);
|
151
|
-
RESET_FAKE(DISPLAY_get_line_insert_index);
|
152
|
-
}
|
153
|
-
|
154
|
-
You might want to define a macro to do this:
|
155
|
-
|
156
|
-
```
|
157
|
-
/* List of fakes used by this unit tester */
|
158
|
-
#define FFF_FAKES_LIST(FAKE) \
|
159
|
-
FAKE(DISPLAY_init) \
|
160
|
-
FAKE(DISPLAY_clear) \
|
161
|
-
FAKE(DISPLAY_output_message) \
|
162
|
-
FAKE(DISPLAY_get_line_capacity) \
|
163
|
-
FAKE(DISPLAY_get_line_insert_index)
|
164
|
-
|
165
|
-
void setup()
|
166
|
-
{
|
167
|
-
/* Register resets */
|
168
|
-
FFF_FAKES_LIST(RESET_FAKE);
|
169
|
-
|
170
|
-
/* reset common FFF internal structures */
|
171
|
-
FFF_RESET_HISTORY();
|
172
|
-
}
|
173
|
-
```
|
174
|
-
|
175
|
-
## Call history
|
176
|
-
Say you want to test that a function calls functionA, then functionB, then
|
177
|
-
functionA again, how would you do that? Well <tt>fff</tt> maintains a call
|
178
|
-
history so that it is easy to assert these expectations.
|
179
|
-
|
180
|
-
Here's how it works:
|
181
|
-
|
182
|
-
FAKE_VOID_FUNC(voidfunc2, char, char);
|
183
|
-
FAKE_VALUE_FUNC(long, longfunc0);
|
184
|
-
|
185
|
-
TEST_F(FFFTestSuite, calls_in_correct_order)
|
186
|
-
{
|
187
|
-
longfunc0();
|
188
|
-
voidfunc2();
|
189
|
-
longfunc0();
|
190
|
-
|
191
|
-
ASSERT_EQ(fff.call_history[0], (void *)longfunc0);
|
192
|
-
ASSERT_EQ(fff.call_history[1], (void *)voidfunc2);
|
193
|
-
ASSERT_EQ(fff.call_history[2], (void *)longfunc0);
|
194
|
-
}
|
195
|
-
|
196
|
-
They are reset by calling <tt>FFF_RESET_HISTORY();</tt>
|
197
|
-
|
198
|
-
|
199
|
-
## Default Argument History
|
200
|
-
|
201
|
-
The framework will by default store the arguments for the last ten calls made
|
202
|
-
to a fake function.
|
203
|
-
|
204
|
-
TEST_F(FFFTestSuite, when_fake_func_called_then_arguments_captured_in_history)
|
205
|
-
{
|
206
|
-
voidfunc2('g', 'h');
|
207
|
-
voidfunc2('i', 'j');
|
208
|
-
ASSERT_EQ('g', voidfunc2_fake.arg0_history[0]);
|
209
|
-
ASSERT_EQ('h', voidfunc2_fake.arg1_history[0]);
|
210
|
-
ASSERT_EQ('i', voidfunc2_fake.arg0_history[1]);
|
211
|
-
ASSERT_EQ('j', voidfunc2_fake.arg1_history[1]);
|
212
|
-
}
|
213
|
-
|
214
|
-
There are two ways to find out if calls have been dropped. The first is to
|
215
|
-
check the dropped histories counter:
|
216
|
-
|
217
|
-
TEST_F(FFFTestSuite, when_fake_func_called_max_times_plus_one_then_one_argument_history_dropped)
|
218
|
-
{
|
219
|
-
int i;
|
220
|
-
for(i = 0; i < 10; i++)
|
221
|
-
{
|
222
|
-
voidfunc2('1'+i, '2'+i);
|
223
|
-
}
|
224
|
-
voidfunc2('1', '2');
|
225
|
-
ASSERT_EQ(1u, voidfunc2_fake.arg_histories_dropped);
|
226
|
-
}
|
227
|
-
|
228
|
-
The other is to check if the call count is greater than the history size:
|
229
|
-
|
230
|
-
ASSERT(voidfunc2_fake.arg_history_len < voidfunc2_fake.call_count);
|
231
|
-
|
232
|
-
The argument histories for a fake function are reset when the RESET_FAKE
|
233
|
-
function is called
|
234
|
-
|
235
|
-
## User Defined Argument History
|
236
|
-
|
237
|
-
If you wish to control how many calls to capture for argument history you can
|
238
|
-
override the default by defining it before include the <tt>fff.h</tt> like this:
|
239
|
-
|
240
|
-
// Want to keep the argument history for 13 calls
|
241
|
-
#define FFF_ARG_HISTORY_LEN 13
|
242
|
-
// Want to keep the call sequence history for 17 function calls
|
243
|
-
#define FFF_CALL_HISTORY_LEN 17
|
244
|
-
|
245
|
-
#include "../fff.h"
|
246
|
-
|
247
|
-
|
248
|
-
## Function Return Value Sequences
|
249
|
-
|
250
|
-
Often in testing we would like to test the behaviour of sequence of function call
|
251
|
-
events. One way to do this with fff is to specify a sequence of return values
|
252
|
-
with for the fake function. It is probably easier to describe with an example:
|
253
|
-
|
254
|
-
// faking "long longfunc();"
|
255
|
-
FAKE_VALUE_FUNC(long, longfunc0);
|
256
|
-
|
257
|
-
TEST_F(FFFTestSuite, return_value_sequences_exhausted)
|
258
|
-
{
|
259
|
-
long myReturnVals[3] = { 3, 7, 9 };
|
260
|
-
SET_RETURN_SEQ(longfunc0, myReturnVals, 3);
|
261
|
-
ASSERT_EQ(myReturnVals[0], longfunc0());
|
262
|
-
ASSERT_EQ(myReturnVals[1], longfunc0());
|
263
|
-
ASSERT_EQ(myReturnVals[2], longfunc0());
|
264
|
-
ASSERT_EQ(myReturnVals[2], longfunc0());
|
265
|
-
ASSERT_EQ(myReturnVals[2], longfunc0());
|
266
|
-
}
|
267
|
-
|
268
|
-
By specifying a return value sequence using the <tt>SET_RETURN_SEQ</tt> macro,
|
269
|
-
the fake will return the values given in the parameter array in sequence. When
|
270
|
-
the end of the sequence is reached the fake will continue to return the last
|
271
|
-
value in the sequence indefinitely.
|
272
|
-
|
273
|
-
## Custom Return Value Delegate
|
274
|
-
|
275
|
-
You can specify your own function to provide the return value for the fake. This
|
276
|
-
is done by setting the custom_fake member of the fake. Here's an example:
|
277
|
-
|
278
|
-
#define MEANING_OF_LIFE 42
|
279
|
-
long my_custom_value_fake(void)
|
280
|
-
{
|
281
|
-
return MEANING_OF_LIFE;
|
282
|
-
}
|
283
|
-
TEST_F(FFFTestSuite, when_value_custom_fake_called_THEN_it_returns_custom_return_value)
|
284
|
-
{
|
285
|
-
longfunc0_fake.custom_fake = my_custom_value_fake;
|
286
|
-
long retval = longfunc0();
|
287
|
-
ASSERT_EQ(MEANING_OF_LIFE, retval);
|
288
|
-
}
|
289
|
-
|
290
|
-
## How do I fake a function that returns a value by reference?
|
291
|
-
The basic mechanism that FFF provides you in this case is the custom_fake field described in the *Custom Return Value Delegate* example above.
|
292
|
-
|
293
|
-
You need to create a custom function (e.g. getTime_custom_fake) to produce the output optionally by use of a helper variable (e.g. getTime_custom_now) to retrieve that output from. Then some creativity to tie it all together. The most important part (IMHO) is to keep your test case readable and maintainable.
|
294
|
-
|
295
|
-
In case your project uses a C99 compliant C compiler you can even combine all this in a single unit test function so you can easily oversee all details of the test. See the example below.
|
296
|
-
|
297
|
-
/* The time structure */
|
298
|
-
typedef struct {
|
299
|
-
int hour, min;
|
300
|
-
} Time;
|
301
|
-
|
302
|
-
/* Our fake function */
|
303
|
-
FAKE_VOID_FUNC(getTime, Time*);
|
304
|
-
|
305
|
-
/* A test using the getTime fake function */
|
306
|
-
TEST_F(FFFTestSuite, when_value_custom_fake_called_THEN_it_returns_custom_output)
|
307
|
-
{
|
308
|
-
Time t;
|
309
|
-
Time getTime_custom_now;
|
310
|
-
void getTime_custom_fake(Time *now) {
|
311
|
-
*now = getTime_custom_now;
|
312
|
-
}
|
313
|
-
getTime_fake.custom_fake = getTime_custom_fake;
|
314
|
-
|
315
|
-
/* given a specific time */
|
316
|
-
getTime_custom_now.hour = 13;
|
317
|
-
getTime_custom_now.min = 05;
|
318
|
-
|
319
|
-
/* when getTime is called */
|
320
|
-
getTime(&t);
|
321
|
-
|
322
|
-
/* then the specific time must be produced */
|
323
|
-
ASSERT_EQ(t.hour, 13);
|
324
|
-
ASSERT_EQ(t.min, 05);
|
325
|
-
}
|
326
|
-
|
327
|
-
## How do I fake a function with a function pointer parameter?
|
328
|
-
Using FFF to stub functions that have function pointer parameter can cause problems when trying to stub them. Presented here is an example how to deal with this situation.
|
329
|
-
|
330
|
-
If you need to stub a function that has a function pointer parameter, e.g. something like:
|
331
|
-
|
332
|
-
```
|
333
|
-
/* timer.h */
|
334
|
-
typedef int timer_handle;
|
335
|
-
extern int timer_start(timer_handle handle, long delay, void (*cb_function) (int arg), int arg);
|
336
|
-
```
|
337
|
-
|
338
|
-
Then creating a fake like below will horribly fail when trying to compile because the FFF macro will internally expand into an illegal variable ```int (*)(int) arg2_val```.
|
339
|
-
|
340
|
-
```
|
341
|
-
/* The fake, attempt one */
|
342
|
-
FAKE_VALUE_FUNC(int,
|
343
|
-
timer_start,
|
344
|
-
timer_handle,
|
345
|
-
long,
|
346
|
-
void (*) (int argument),
|
347
|
-
int);
|
348
|
-
```
|
349
|
-
|
350
|
-
The solution to this problem is to create a bridging type that needs only to be visible in the unit tester. The fake will use that intermediate type. This way the compiler will not complain because the types match.
|
351
|
-
|
352
|
-
```
|
353
|
-
/* Additional type needed to be able to use callback in FFF */
|
354
|
-
typedef void (*timer_cb) (int argument);
|
355
|
-
|
356
|
-
/* The fake, attempt two */
|
357
|
-
FAKE_VALUE_FUNC(int,
|
358
|
-
timer_start,
|
359
|
-
timer_handle,
|
360
|
-
long,
|
361
|
-
timer_cb,
|
362
|
-
int);
|
363
|
-
```
|
364
|
-
|
365
|
-
Here are some ideas how to create a test case with callbacks.
|
366
|
-
|
367
|
-
```
|
368
|
-
/* Unit test */
|
369
|
-
TEST_F(FFFTestSuite, test_fake_with_function_pointer)
|
370
|
-
{
|
371
|
-
int cb_timeout_called = 0;
|
372
|
-
int result = 0;
|
373
|
-
|
374
|
-
void cb_timeout(int argument)
|
375
|
-
{
|
376
|
-
cb_timeout_called++;
|
377
|
-
}
|
378
|
-
|
379
|
-
int timer_start_custom_fake(timer_handle handle,
|
380
|
-
long delay,
|
381
|
-
void (*cb_function) (int arg),
|
382
|
-
int arg)
|
383
|
-
{
|
384
|
-
if (cb_function) cb_function(arg);
|
385
|
-
return timer_start_fake.return_val;
|
386
|
-
}
|
387
|
-
|
388
|
-
/* given the custom fake for timer_start */
|
389
|
-
timer_start_fake.return_val = 33;
|
390
|
-
timer_start_fake.custom_fake = timer_start_custom_fake;
|
391
|
-
|
392
|
-
/* when timer_start is called
|
393
|
-
* (actually you would call your own function-under-test
|
394
|
-
* that would then call the fake function)
|
395
|
-
*/
|
396
|
-
result = timer_start(10, 100, cb_timeout, 55);
|
397
|
-
|
398
|
-
/* then the timer_start fake must have been called correctly */
|
399
|
-
ASSERT_EQ(result, 33);
|
400
|
-
ASSERT_EQ(timer_start_fake.call_count, 1);
|
401
|
-
ASSERT_EQ(timer_start_fake.arg0_val, 10);
|
402
|
-
ASSERT_EQ(timer_start_fake.arg1_val, 100);
|
403
|
-
ASSERT_EQ(timer_start_fake.arg2_val, cb_timeout); /* callback provided by unit tester */
|
404
|
-
ASSERT_EQ(timer_start_fake.arg3_val, 55);
|
405
|
-
|
406
|
-
/* and ofcourse our custom fake correctly calls the registered callback */
|
407
|
-
ASSERT_EQ(cb_timeout_called, 1);
|
408
|
-
}
|
409
|
-
```
|
410
|
-
|
411
|
-
## Find out more...
|
412
|
-
|
413
|
-
Look under the examlples directory for full length examples in both C and C++.
|
414
|
-
There is also a test suite for the framework under the test directory.
|
415
|
-
|
416
|
-
-------------------------
|
417
|
-
|
418
|
-
## Benefits
|
419
|
-
So whats the point?
|
420
|
-
|
421
|
-
* To make it easy to create fake functions for testing C code.
|
422
|
-
* It is simple - just include a header file and you are good to go.
|
423
|
-
* To work in both C and C++ test environments
|
424
|
-
|
425
|
-
|
426
|
-
## Under the hood:
|
427
|
-
* The fff.h header file is generated by a ruby script
|
428
|
-
* There are tests under src/test
|
429
|
-
* There is an example for testing an embedded UI and a hardware driver under src/examples
|
430
|
-
|
431
|
-
|
432
|
-
## Cheat Sheet
|
433
|
-
<table>
|
434
|
-
<tr>
|
435
|
-
<th>Macro</th>
|
436
|
-
<th>Description</th>
|
437
|
-
<th>Example</th>
|
438
|
-
</tr>
|
439
|
-
<tr>
|
440
|
-
<td>FAKE_VOID_FUNC(fn [,arg_types*]);</td>
|
441
|
-
<td>Define a fake function named fn returning void with n arguments</td>
|
442
|
-
<td>FAKE_VOID_FUNC(DISPLAY_output_message, const char*);</td>
|
443
|
-
</tr>
|
444
|
-
<tr>
|
445
|
-
<td>FAKE_VALUE_FUNC(return_type, fn [,arg_types*]);</td>
|
446
|
-
<td>Define a fake function returning a value with type return_type taking n arguments</td>
|
447
|
-
<td>FAKE_VALUE_FUNC(int, DISPLAY_get_line_insert_index);</td>
|
448
|
-
</tr>
|
449
|
-
<tr>
|
450
|
-
<td>RESET_FAKE(fn);</td>
|
451
|
-
<td>Reset the state of fake function called fn</td>
|
452
|
-
<td>RESET_FAKE(DISPLAY_init);</td>
|
453
|
-
</tr>
|
454
|
-
</table>
|