Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Backport "fix: scoverage statement's line number should be 1-base" to LTS #19236

Merged
merged 4 commits into from
Dec 13, 2023

Commits on Dec 11, 2023

  1. fix: scoverage statement's line number should be 1-base

    fix #18916
    
    This PR makes scoverage statements' line number 1-base,
    instead of 0-base, as @tarao described.
    
    It would be ideal if we could find specifications of many of
    coverage report fomats (such as Jacoco XML, cobertura.xml, lcov.txt...)
    and confirm most of them expect the line numbers 1-base.
    
    However, it seems there's no formal specification for them AFAIK.
    Since we've been using 1-base so far in Scala2 and it hasn't been a problem,
    so I guess it's OK to change to 1-base (and most of coverage report
    format and visualizer expect 1-base maybe).
    
    I believe it should be reporter / aggregator's responsibility to
    adjust the line numbers if some coverage format expects 0-base.
    
    Add doc comment to Statement @param line that it's 1-base
    
    Update scoverage.check files
    
    sbt> scala3-compiler-bootstrapped / Test / testCompilation --update-checkfiles
    
    [Cherry-picked 86aaea9]
    tanishiking authored and Kordyjan committed Dec 11, 2023
    Configuration menu
    Copy the full SHA
    04da287 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    8cc12b3 View commit details
    Browse the repository at this point in the history

Commits on Dec 13, 2023

  1. Fix more test leftovers

    Kordyjan committed Dec 13, 2023
    Configuration menu
    Copy the full SHA
    1788393 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    12468e3 View commit details
    Browse the repository at this point in the history