Skip to content

Commit

Permalink
✅ Fixed gcov ReportGenerator testing
Browse files Browse the repository at this point in the history
  • Loading branch information
mkarlesky committed May 13, 2024
1 parent fe3fb78 commit a269634
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions spec/gcov/gcov_test_cases_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -194,8 +194,9 @@ def can_create_html_report

output = `bundle exec ruby -S ceedling gcov:all`
expect(output).to match(/Generating HTML coverage report in 'build\/artifacts\/gcov\/gcovr'\.\.\./)
expect(output).to match(/Generating HtmlBasic coverage report in 'build\/artifacts\/gcov\/ReportGenerator'\.\.\./)
expect(File.exist?('build/artifacts/gcov/gcovr/GcovCoverageResults.html')).to eq true
expect(File.exist?('build/artifacts/gcov/reportgenerator/summary.htm')).to eq true
expect(File.exist?('build/artifacts/gcov/ReportGenerator/summary.htm')).to eq true
end
end
end
Expand Down Expand Up @@ -223,10 +224,10 @@ def can_create_gcov_html_report_from_crashing_test_runner_with_enabled_debug_and
expect(output).to match(/FAILED:\s+(?:1|2)/)
expect(output).to match(/IGNORED:\s+0/)
expect(output).to match(/example_file.c \| Lines executed:5?0.00% of 4/)

expect(output).to match(/Generating HTML coverage report in 'build\/artifacts\/gcov\/gcovr'\.\.\./)
expect(output).to match(/Done/)
expect(output).to match(/Generating HtmlBasic coverage report in 'build\/artifacts\/gcov\/ReportGenerator'\.\.\./)
expect(File.exist?('build/artifacts/gcov/gcovr/GcovCoverageResults.html')).to eq true
expect(File.exist?('build/artifacts/gcov/ReportGenerator/summary.htm')).to eq true
end
end
end
Expand Down Expand Up @@ -256,8 +257,9 @@ def can_create_gcov_html_report_from_crashing_test_runner_with_enabled_debug_and
expect(output).to match(/example_file.c \| Lines executed:0.00% of 4/)

expect(output).to match(/Generating HTML coverage report in 'build\/artifacts\/gcov\/gcovr'\.\.\./)
expect(output).to match(/Done/)
expect(output).to match(/Generating HtmlBasic coverage report in 'build\/artifacts\/gcov\/ReportGenerator'\.\.\./)
expect(File.exist?('build/artifacts/gcov/gcovr/GcovCoverageResults.html')).to eq true
expect(File.exist?('build/artifacts/gcov/ReportGenerator/summary.htm')).to eq true
end
end
end
Expand Down Expand Up @@ -291,8 +293,9 @@ def can_create_gcov_html_report_from_test_runner_with_enabled_debug_and_cmd_args
expect(output).to match(/example_file.c \| Lines executed:100.00% of 4/)

expect(output).to match(/Generating HTML coverage report in 'build\/artifacts\/gcov\/gcovr'\.\.\./)
expect(output).to match(/Done/)
expect(output).to match(/Generating HtmlBasic coverage report in 'build\/artifacts\/gcov\/ReportGenerator'\.\.\./)
expect(File.exist?('build/artifacts/gcov/gcovr/GcovCoverageResults.html')).to eq true
expect(File.exist?('build/artifacts/gcov/ReportGenerator/summary.htm')).to eq true
end
end
end
Expand Down

0 comments on commit a269634

Please sign in to comment.