forking_test_runner 1.9.0 → 1.10.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 33abc47d33141843b1d89ce17adee27897c64bc3445d9567845194aaa9f07224
4
- data.tar.gz: a61958472117f965f21e354ce7f874f7ea920a76503589b5dd36e0a6f21eb7c7
3
+ metadata.gz: 1839ef1db8973b5e282bbf3998915649fa16448e12d6c56e11fda8b0d1f4d2a8
4
+ data.tar.gz: 8d3f007a2149807efd62c4e1ff4b9a287c54055aebc3760b6bd3300d5844e8bf
5
5
  SHA512:
6
- metadata.gz: 59f31396b4c6ccdce8cb625aebdea2b3f2a49c6e91983990f2b93e386c19f8e6ef94100d8ca0482a0e82cec2450fb1a5db1a47c42566749b69d7324543676c87
7
- data.tar.gz: 32bbc0a83affacf06da8943e9a592152841ead2d7180aabe201031934d68705ac9e769c9c75b33b13b0a4b1587f6795fb38bbdb44c145f4e5c3de74bd698dab3
6
+ metadata.gz: 4939fa2877d285718946f957082a2129b17d4d20d7cce27050709d81d4c410bd50c455af8c2d546a3ebeaaa76a7ac047859883ea1b780102f8af63ac12ae14a5
7
+ data.tar.gz: 25caf6564292c4cd5d74b9214879d514b6d9b49ac11c8bcf9e3e1407e0550ece85d92f6ed3395015ff028b1c654578d9d05d17f2b708c9e6e59ffdf590a49d3e
@@ -375,7 +375,11 @@ module ForkingTestRunner
375
375
  File.unlink(report) # do not leave junk behind
376
376
  end
377
377
 
378
- data = JSON.pretty_generate("Unit Tests" => {"coverage" => coverage, "timestamp" => Time.now.to_i })
378
+ # report only line coverage to be backwards compatible for some coverage backends
379
+ coverage.transform_values! { |v| v.is_a?(Hash) ? v.fetch(:lines) : v } if @options[:report_line_coverage]
380
+
381
+ # chose "Minitest" because it is what simplecov uses for reports and "Unit Tests" makes sonarqube break
382
+ data = JSON.pretty_generate("Minitest" => {"coverage" => coverage, "timestamp" => Time.now.to_i })
379
383
  File.write(SingleCov.coverage_report, data)
380
384
 
381
385
  # make it not override our report when it finishes for main process
@@ -7,7 +7,8 @@ module ForkingTestRunner
7
7
  [:quiet, "--quiet", "Quiet"],
8
8
  [:no_fixtures, "--no-fixtures", "Do not load fixtures"],
9
9
  [:no_ar, "--no-ar", "Disable ActiveRecord logic"],
10
- [:merge_coverage, "--merge-coverage", "Merge base code coverage into indvidual files coverage, great for SingleCov"],
10
+ [:merge_coverage, "--merge-coverage", "Merge base code coverage into individual files coverage and summarize coverage report"],
11
+ [:report_line_coverage, "--report-line-coverage", "Convert coverage report to line coverage (for compatibility)"],
11
12
  [
12
13
  :record_runtime,
13
14
  "--record-runtime=MODE",
@@ -1,3 +1,3 @@
1
1
  module ForkingTestRunner
2
- VERSION = "1.9.0"
2
+ VERSION = "1.10.0"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: forking_test_runner
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.9.0
4
+ version: 1.10.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Grosser