ceedling 1.1.5 → 1.1.7
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.
- checksums.yaml +4 -4
- data/GIT_COMMIT_SHA +1 -1
- data/Gemfile +4 -0
- data/Gemfile.lock +2 -0
- data/README.md +4 -1
- data/assets/tests_with_conditional_includes/src/feature_config.h +13 -0
- data/assets/tests_with_conditional_includes/src/feature_extra.h +13 -0
- data/assets/tests_with_conditional_includes/src/local_flag_extra.h +13 -0
- data/assets/tests_with_conditional_includes/src/nested_extra.h +13 -0
- data/assets/tests_with_conditional_includes/src/nested_wrapper.h +16 -0
- data/assets/tests_with_conditional_includes/src/project_flag_extra.h +13 -0
- data/assets/tests_with_conditional_includes/src/widget.c +48 -0
- data/assets/tests_with_conditional_includes/src/widget.h +15 -0
- data/assets/tests_with_conditional_includes/src/widget_feature.c +29 -0
- data/assets/tests_with_conditional_includes/src/widget_feature.h +13 -0
- data/assets/tests_with_conditional_includes/test/test_widget.c +44 -0
- data/assets/tests_with_conditional_includes/test/test_widget_feature.c +31 -0
- data/docs/Changelog.md +31 -1
- data/docs/KnownIssues.md +1 -0
- data/docs/mkdocs/configuration/project-file.md +25 -7
- data/docs/mkdocs/configuration/reference/cexception.md +1 -1
- data/docs/mkdocs/configuration/reference/cmock.md +1 -1
- data/docs/mkdocs/configuration/reference/unity.md +1 -1
- data/docs/mkdocs/getting-started/quick-start.md +11 -8
- data/docs/mkdocs/plugins/gcov/gcovr.md +324 -189
- data/docs/mkdocs/plugins/gcov/reportgenerator.md +113 -31
- data/docs/mkdocs/reference/gcov-plugin.md +21 -3
- data/docs/mkdocs/snapshot/plugins/gcov/config/defaults.yml +0 -1
- data/examples/wondrous_forest/src/SensorHal.h +13 -0
- data/examples/wondrous_forest/src/TemperatureSensor.c +12 -5
- data/examples/wondrous_forest/src/TemperatureSensor.h +5 -4
- data/examples/wondrous_forest/test/TestTemperatureSensor.c +32 -3
- data/lib/ceedling/generators/generator_test_results_backtrace.rb +16 -8
- data/lib/ceedling/generators/generator_test_runner.rb +25 -1
- data/lib/ceedling/partials/partializer.rb +8 -1
- data/lib/ceedling/plugins/plugin_reportinator.rb +9 -0
- data/lib/ceedling/plugins/report_tests_stdout_plugin.rb +1 -1
- data/lib/ceedling/preprocess/preprocessinator.rb +22 -0
- data/lib/ceedling/preprocess/preprocessinator_includes_handler.rb +33 -0
- data/lib/version.rb +1 -1
- data/plugins/gcov/config/defaults.yml +0 -1
- data/plugins/gcov/lib/gcov.rb +35 -16
- data/plugins/gcov/lib/gcovr_reportinator.rb +31 -1
- data/plugins/valgrind/lib/valgrind.rb +1 -1
- data/site-local/configuration/project-file.html +78 -8
- data/site-local/configuration/reference/cexception.html +5 -5
- data/site-local/configuration/reference/cmock.html +5 -5
- data/site-local/configuration/reference/unity.html +5 -5
- data/site-local/getting-started/quick-start.html +13 -9
- data/site-local/plugins/gcov/gcovr.html +1215 -255
- data/site-local/plugins/gcov/reportgenerator.html +404 -46
- data/site-local/reference/gcov-plugin.html +40 -7
- data/site-local/sitemap.xml.gz +0 -0
- data/site-local/snapshot/plugins/gcov/config/defaults.yml +0 -1
- data/spec/support/system/spec_system_helper.rb +11 -0
- data/spec/support/system/system_context.rb +25 -12
- data/spec/system/conditional_include_macro_visibility_spec.rb +152 -0
- data/spec/system/deployment_as_gem_spec.rb +2 -0
- data/spec/system/deployment_as_vendor_spec.rb +2 -0
- data/spec/system/encoding_stress_spec.rb +4 -4
- data/spec/system/example_wondrous_forest_spec.rb +2 -2
- data/spec/system/gcov_deployment_spec.rb +2 -0
- data/spec/system/support/common_test_cases.rb +47 -1
- data/spec/system/support/gcov_common_test_cases.rb +52 -0
- data/spec/system/test_runner_system_include_spec.rb +90 -0
- data/spec/units/generators/generator_test_results_backtrace_spec.rb +51 -0
- data/spec/units/generators/generator_test_runner_spec.rb +69 -0
- data/spec/units/partials/partializer_spec.rb +69 -0
- data/spec/units/plugin_reportinator_spec.rb +38 -0
- data/spec/units/preprocess/preprocessinator_includes_handler_spec.rb +61 -0
- data/spec/units/preprocess/preprocessinator_spec.rb +136 -0
- data/vendor/c_exception/lib/CException.h +1 -1
- data/vendor/c_exception/project.yml +2 -2
- data/vendor/c_exception/test/TestException.c +1 -1
- data/vendor/c_exception/test/support/CExceptionConfig.h +5 -11
- data/vendor/cmock/docs/CMockChangeLog.md +23 -22
- data/vendor/cmock/scripts/create_makefile.rb +4 -3
- data/vendor/cmock/src/cmock.h +1 -1
- data/vendor/cmock/vendor/c_exception/lib/CException.h +1 -1
- data/vendor/cmock/vendor/c_exception/project.yml +2 -2
- data/vendor/cmock/vendor/c_exception/test/TestException.c +1 -1
- data/vendor/cmock/vendor/c_exception/test/support/CExceptionConfig.h +5 -11
- data/vendor/cmock/vendor/unity/auto/generate_test_runner.rb +85 -29
- data/vendor/cmock/vendor/unity/docs/UnityChangeLog.md +1 -0
- data/vendor/cmock/vendor/unity/examples/unity_config.h +8 -0
- data/vendor/cmock/vendor/unity/src/unity.c +9 -1
- data/vendor/cmock/vendor/unity/src/unity.h +1 -1
- data/vendor/cmock/vendor/unity/test/rakefile +2 -1
- data/vendor/cmock/vendor/unity/test/testdata/testRunnerGeneratorEmpty.c +13 -0
- data/vendor/cmock/vendor/unity/test/tests/test_generate_test_runner.rb +31 -0
- data/vendor/unity/auto/generate_test_runner.rb +63 -57
- data/vendor/unity/docs/UnityChangeLog.md +1 -0
- data/vendor/unity/examples/unity_config.h +8 -0
- data/vendor/unity/src/unity.c +9 -1
- data/vendor/unity/src/unity.h +1 -1
- data/vendor/unity/test/rakefile +2 -1
- data/vendor/unity/test/tests/test_generate_test_runner.rb +20 -0
- metadata +23 -3
- data/vendor/cmock/vendor/unity/auto/run_test.erb +0 -37
|
@@ -1314,6 +1314,26 @@ def verify_number(expected, expression, output)
|
|
|
1314
1314
|
end
|
|
1315
1315
|
end
|
|
1316
1316
|
|
|
1317
|
+
should 'GenerateSuiteTeardownWhenBeginAndEndAreOmitted' do
|
|
1318
|
+
runner_name = OUT_FILE + 'SuiteTeardownWithoutBeginEnd_runner.c'
|
|
1319
|
+
UnityTestRunnerGenerator.new(
|
|
1320
|
+
:test_prefix => 'test',
|
|
1321
|
+
:suite_teardown => ' return num_failures;',
|
|
1322
|
+
:omit_begin_end => true,
|
|
1323
|
+
).run('testdata/testRunnerGenerator.c', runner_name)
|
|
1324
|
+
|
|
1325
|
+
runner = File.read(runner_name)
|
|
1326
|
+
correct_call = runner.include?('(void) suiteTearDown(0);')
|
|
1327
|
+
incorrect_call = runner.include?('(void) suite_teardown(0);')
|
|
1328
|
+
if correct_call && !incorrect_call
|
|
1329
|
+
report 'Runner_GenerateSuiteTeardownWhenBeginAndEndAreOmitted:PASS'
|
|
1330
|
+
else
|
|
1331
|
+
report 'Runner_GenerateSuiteTeardownWhenBeginAndEndAreOmitted:FAIL'
|
|
1332
|
+
$generate_test_runner_failures += 1
|
|
1333
|
+
end
|
|
1334
|
+
$generate_test_runner_tests += 1
|
|
1335
|
+
end
|
|
1336
|
+
|
|
1317
1337
|
RUNNER_TESTS.each do |testset|
|
|
1318
1338
|
basename = File.basename(testset[:testfile], C_EXTENSION)
|
|
1319
1339
|
testset_name = "Runner_#{basename}_#{testset[:name]}"
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: ceedling
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.1.
|
|
4
|
+
version: 1.1.7
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Mark VanderVoord
|
|
@@ -10,7 +10,7 @@ authors:
|
|
|
10
10
|
autorequire:
|
|
11
11
|
bindir: bin
|
|
12
12
|
cert_chain: []
|
|
13
|
-
date: 2026-
|
|
13
|
+
date: 2026-09-04 00:00:00.000000000 Z
|
|
14
14
|
dependencies:
|
|
15
15
|
- !ruby/object:Gem::Dependency
|
|
16
16
|
name: rake
|
|
@@ -203,6 +203,18 @@ files:
|
|
|
203
203
|
- assets/test_example_with_parameterized_tests.c
|
|
204
204
|
- assets/test_partial_all_module.c
|
|
205
205
|
- assets/test_same_dir_pairing.c
|
|
206
|
+
- assets/tests_with_conditional_includes/src/feature_config.h
|
|
207
|
+
- assets/tests_with_conditional_includes/src/feature_extra.h
|
|
208
|
+
- assets/tests_with_conditional_includes/src/local_flag_extra.h
|
|
209
|
+
- assets/tests_with_conditional_includes/src/nested_extra.h
|
|
210
|
+
- assets/tests_with_conditional_includes/src/nested_wrapper.h
|
|
211
|
+
- assets/tests_with_conditional_includes/src/project_flag_extra.h
|
|
212
|
+
- assets/tests_with_conditional_includes/src/widget.c
|
|
213
|
+
- assets/tests_with_conditional_includes/src/widget.h
|
|
214
|
+
- assets/tests_with_conditional_includes/src/widget_feature.c
|
|
215
|
+
- assets/tests_with_conditional_includes/src/widget_feature.h
|
|
216
|
+
- assets/tests_with_conditional_includes/test/test_widget.c
|
|
217
|
+
- assets/tests_with_conditional_includes/test/test_widget_feature.c
|
|
206
218
|
- assets/tests_with_defines/src/adc_hardware.c
|
|
207
219
|
- assets/tests_with_defines/src/adc_hardware.h
|
|
208
220
|
- assets/tests_with_defines/src/adc_hardware_configurator.c
|
|
@@ -923,6 +935,7 @@ files:
|
|
|
923
935
|
- spec/support/test_example_ignore.pass
|
|
924
936
|
- spec/support/test_example_mangled.pass
|
|
925
937
|
- spec/support/test_example_with_time.pass
|
|
938
|
+
- spec/system/conditional_include_macro_visibility_spec.rb
|
|
926
939
|
- spec/system/cppcheck_deployment_spec.rb
|
|
927
940
|
- spec/system/deployment_as_gem_spec.rb
|
|
928
941
|
- spec/system/deployment_as_vendor_spec.rb
|
|
@@ -945,6 +958,7 @@ files:
|
|
|
945
958
|
- spec/system/support/gcov_partials_test_cases.rb
|
|
946
959
|
- spec/system/support/valgrind_common_test_cases.rb
|
|
947
960
|
- spec/system/support/valgrind_helpers.rb
|
|
961
|
+
- spec/system/test_runner_system_include_spec.rb
|
|
948
962
|
- spec/system/upgrade_as_vendor_spec.rb
|
|
949
963
|
- spec/system/valgrind_deployment_spec.rb
|
|
950
964
|
- spec/units/bin/cli_helper_spec.rb
|
|
@@ -982,6 +996,7 @@ files:
|
|
|
982
996
|
- spec/units/partials/partializer_spec.rb
|
|
983
997
|
- spec/units/partials/partializer_utils_spec.rb
|
|
984
998
|
- spec/units/plugin_manager_spec.rb
|
|
999
|
+
- spec/units/plugin_reportinator_spec.rb
|
|
985
1000
|
- spec/units/plugins/cppcheck_spec.rb
|
|
986
1001
|
- spec/units/preprocess/c_comment_scanner_spec.rb
|
|
987
1002
|
- spec/units/preprocess/c_preprocessor_conditionals_spec.rb
|
|
@@ -990,6 +1005,7 @@ files:
|
|
|
990
1005
|
- spec/units/preprocess/preprocessinator_file_assembler_spec.rb
|
|
991
1006
|
- spec/units/preprocess/preprocessinator_includes_handler_spec.rb
|
|
992
1007
|
- spec/units/preprocess/preprocessinator_reconstructor_spec.rb
|
|
1008
|
+
- spec/units/preprocess/preprocessinator_spec.rb
|
|
993
1009
|
- spec/units/reportinator_spec.rb
|
|
994
1010
|
- spec/units/ruby_expandinator_spec.rb
|
|
995
1011
|
- spec/units/system_utils_spec.rb
|
|
@@ -1306,7 +1322,6 @@ files:
|
|
|
1306
1322
|
- vendor/cmock/vendor/unity/auto/generate_module.rb
|
|
1307
1323
|
- vendor/cmock/vendor/unity/auto/generate_test_runner.rb
|
|
1308
1324
|
- vendor/cmock/vendor/unity/auto/parse_output.rb
|
|
1309
|
-
- vendor/cmock/vendor/unity/auto/run_test.erb
|
|
1310
1325
|
- vendor/cmock/vendor/unity/auto/stylize_as_junit.py
|
|
1311
1326
|
- vendor/cmock/vendor/unity/auto/stylize_as_junit.rb
|
|
1312
1327
|
- vendor/cmock/vendor/unity/auto/test_file_filter.rb
|
|
@@ -1449,6 +1464,7 @@ files:
|
|
|
1449
1464
|
- vendor/cmock/vendor/unity/test/testdata/cmock.h
|
|
1450
1465
|
- vendor/cmock/vendor/unity/test/testdata/mockMock.h
|
|
1451
1466
|
- vendor/cmock/vendor/unity/test/testdata/testRunnerGenerator.c
|
|
1467
|
+
- vendor/cmock/vendor/unity/test/testdata/testRunnerGeneratorEmpty.c
|
|
1452
1468
|
- vendor/cmock/vendor/unity/test/testdata/testRunnerGeneratorSmall.c
|
|
1453
1469
|
- vendor/cmock/vendor/unity/test/testdata/testRunnerGeneratorWithMocks.c
|
|
1454
1470
|
- vendor/cmock/vendor/unity/test/tests/self_assessment_utils.h
|
|
@@ -1771,6 +1787,7 @@ test_files:
|
|
|
1771
1787
|
- spec/support/test_example_ignore.pass
|
|
1772
1788
|
- spec/support/test_example_mangled.pass
|
|
1773
1789
|
- spec/support/test_example_with_time.pass
|
|
1790
|
+
- spec/system/conditional_include_macro_visibility_spec.rb
|
|
1774
1791
|
- spec/system/cppcheck_deployment_spec.rb
|
|
1775
1792
|
- spec/system/deployment_as_gem_spec.rb
|
|
1776
1793
|
- spec/system/deployment_as_vendor_spec.rb
|
|
@@ -1793,6 +1810,7 @@ test_files:
|
|
|
1793
1810
|
- spec/system/support/gcov_partials_test_cases.rb
|
|
1794
1811
|
- spec/system/support/valgrind_common_test_cases.rb
|
|
1795
1812
|
- spec/system/support/valgrind_helpers.rb
|
|
1813
|
+
- spec/system/test_runner_system_include_spec.rb
|
|
1796
1814
|
- spec/system/upgrade_as_vendor_spec.rb
|
|
1797
1815
|
- spec/system/valgrind_deployment_spec.rb
|
|
1798
1816
|
- spec/units/bin/cli_helper_spec.rb
|
|
@@ -1830,6 +1848,7 @@ test_files:
|
|
|
1830
1848
|
- spec/units/partials/partializer_spec.rb
|
|
1831
1849
|
- spec/units/partials/partializer_utils_spec.rb
|
|
1832
1850
|
- spec/units/plugin_manager_spec.rb
|
|
1851
|
+
- spec/units/plugin_reportinator_spec.rb
|
|
1833
1852
|
- spec/units/plugins/cppcheck_spec.rb
|
|
1834
1853
|
- spec/units/preprocess/c_comment_scanner_spec.rb
|
|
1835
1854
|
- spec/units/preprocess/c_preprocessor_conditionals_spec.rb
|
|
@@ -1838,6 +1857,7 @@ test_files:
|
|
|
1838
1857
|
- spec/units/preprocess/preprocessinator_file_assembler_spec.rb
|
|
1839
1858
|
- spec/units/preprocess/preprocessinator_includes_handler_spec.rb
|
|
1840
1859
|
- spec/units/preprocess/preprocessinator_reconstructor_spec.rb
|
|
1860
|
+
- spec/units/preprocess/preprocessinator_spec.rb
|
|
1841
1861
|
- spec/units/reportinator_spec.rb
|
|
1842
1862
|
- spec/units/ruby_expandinator_spec.rb
|
|
1843
1863
|
- spec/units/system_utils_spec.rb
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
/*=======Test Runner Used To Run Each Test=====*/
|
|
2
|
-
static void run_test(UnityTestFunction func, const char* name, UNITY_LINE_TYPE line_num)
|
|
3
|
-
{
|
|
4
|
-
Unity.CurrentTestName = name;
|
|
5
|
-
Unity.CurrentTestLineNumber = (UNITY_UINT) line_num;
|
|
6
|
-
#ifdef UNITY_USE_COMMAND_LINE_ARGS
|
|
7
|
-
if (!UnityTestMatches())
|
|
8
|
-
return;
|
|
9
|
-
#endif
|
|
10
|
-
Unity.NumberOfTests++;
|
|
11
|
-
UNITY_CLR_DETAILS();
|
|
12
|
-
UNITY_EXEC_TIME_START();
|
|
13
|
-
CMock_Init();
|
|
14
|
-
if (TEST_PROTECT())
|
|
15
|
-
{
|
|
16
|
-
<% if @options[:plugins].include?(:cexception) %>
|
|
17
|
-
volatile CEXCEPTION_T e;
|
|
18
|
-
Try {
|
|
19
|
-
<%= @options[:setup_name] %>();
|
|
20
|
-
func();
|
|
21
|
-
} Catch(e) {
|
|
22
|
-
TEST_ASSERT_EQUAL_HEX32_MESSAGE(CEXCEPTION_NONE, e, "Unhandled Exception!");
|
|
23
|
-
}
|
|
24
|
-
<% else %>
|
|
25
|
-
<%= @options[:setup_name] %>();
|
|
26
|
-
func();
|
|
27
|
-
<% end %>
|
|
28
|
-
}
|
|
29
|
-
if (TEST_PROTECT())
|
|
30
|
-
{
|
|
31
|
-
<%= @options[:teardown_name] %>();
|
|
32
|
-
CMock_Verify();
|
|
33
|
-
}
|
|
34
|
-
CMock_Destroy();
|
|
35
|
-
UNITY_EXEC_TIME_STOP();
|
|
36
|
-
UnityConcludeTest();
|
|
37
|
-
}
|