Update dependency simplecov to v1.3.0 - #484
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
1.2.0→1.3.0Release Notes
simplecov-ruby/simplecov (simplecov)
v1.3.0Compare Source
==================
SimpleCov 1.3 raises the minimum Ruby to 3.3, brings the coverage directives to ERB, Haml, and Slim templates,
teaches
simplecov patchandsimplecov uncoveredto annotate CI hosts natively, and settles what the report saysabout files and groups that hold nothing.
Highlights
# simplecov:disableand# simplecov:enablework inside ERB, Haml, and Slim templates measured withcover_views, in each language's own comment syntax or as Ruby comments on a code line.--annotate KINDturnssimplecov patchandsimplecov uncoveredinto inline CI annotations for GitHub, GitLab, reviewdog, Azure, TeamCity, and Buildkite, so one CI step can both annotate and gate.railsprofile declares its groups alphabetically.cover_viewsis the only way to measure a template now: acoverglob that matches one warns and leaves it out, andignore: :eval_generatedno longer drops a template's real branches and methods.Upgrade notes
coverage.json, and the history file, and a per-group minimum on it passes silently rather than complaining that the group does not exist.railsprofile's group tabs come out in alphabetical order, so an existing project's tabs move.coverglob matching.erb,.haml, or.slimwarns and drops those files from the report. Measure templates withcover_viewsinstead.coverage.jsonstays at schema 1.3, unchanged by this release.Breaking Changes
required_ruby_version >= 3.3), with JRuby 10 still supported and TruffleRuby exercised only by the nightly unstable build. Prism is bundled with every supported Ruby, so the static coverage extractor stops probing for it:StaticCoverageExtractor.available?and the empty-hash fallbacks for its absence are gone. So is the emulation of Ruby 3.2's constant folding, where parentheses were transparent for every literal and a folded dead arm's branches survived in the branch table.Enhancements
# simplecov:disableand# simplecov:enablework inside ERB, Haml, and Slim templates measured withcover_views, in each language's own comment syntax (<%# simplecov:disable %>,-# simplecov:disable,/ simplecov:disable) or as Ruby comments on a code line. A template's directives were never found before: the comment scan tokenizes a file as Ruby, and in ERB%>opens a percent literal that swallowed every comment after the template's first tag, while Haml and Slim comments are not Ruby comments at all and a Slim- # simplecov:disableline even read as an inline directive that disabled only itself. The scan now reads only the Ruby a template holds, at the template's own lines, so a Devise app can disable theconfirmablelink it never renders instead of carrying it as uncovered. See #1295.coverage.json, and the history file all skip them, so therailsprofile'sChannels,Mailers, andViewstabs no longer pad the HTML report of an app without those directories, and a project can declare a group per directory it might have (Dir["app/*"].each { |dir| group File.basename(dir).capitalize, dir }) without checking each one for Ruby files first. Aminimum_coverage_by_groupthreshold on a group that matched nothing passes silently, as it did when the empty group reported 100%, rather than complaining that the group does not exist. See #1293.railsprofile declares its groups in alphabetical order:Channels,Controllers,Helpers,Jobs,Libraries,Mailers,Models,Views. Group tabs render in declaration order, so the report of a Rails app lists them that way instead of in the order they accumulated over the years. Nothing else about the groups changes, and a project that declares its own groups is unaffected.simplecov patchandsimplecov uncoveredannotate CI hosts natively.--annotate KINDon both commands turns the answer into inline annotations in the host's own channel, one per contiguous missed range with project-relative paths (patchadds one per uncovered touched branch or method when the report measured them):githubemits::warningworkflow commands,gitlaba Code Quality report for thecodequalityartifact,rdjsonreviewdog's Diagnostic Format for any host reviewdog posts to,azure##vso[task.logissue]logging commands,teamcitycode inspection service messages, andbuildkitethe Markdown body forbuildkite-agent annotate.uncoveredpreviously offered onlygithub, and its annotations now name the chosen criterion the waypatch's do. Nothing else reaches stdout in that mode andpatch --minimumstill sets the exit status, so one CI step can annotate and gate. Documented under CI annotations in docs/CLI.md.Bugfixes
coverglob that matches a template warns and leaves it out instead of simulating it. Simulation classifies lines as Ruby and parses for branches, so a swept-in template appeared with a comment counted as a missed line, an#idtag counted as never relevant, and no branches at all. The warning names the templates and points atcover_views, which compiles them and measures the real thing.# :nocov:toggle works in a template's own comment syntax (<%# :nocov: %>,-# :nocov:,/ :nocov:) and emits its deprecation warning there. The matcher read raw lines and needed the line to begin with#, so those forms were silently ignored while the Ruby-comment form inside an ERB code tag happened to work. The matcher now reads the same extracted Ruby the directives do.ignore: :eval_generatedno longer drops a template's real branches and methods. The filter keeps a Coverage entry only when Prism finds a matching construct in the static source, which for a template measured withcover_viewsmeant parsing ERB, Haml, or Slim as Ruby. That usually fails and the entry is kept, but a template whose text happens to parse (a Haml or Slim#idtag reads as a Ruby comment, and so does an ERB text line starting with#) yielded a confident wrong parse, and the template's own conditionals vanished from branch coverage. Templates now skip the parse, since everything a template reports is eval-generated by construction and the filter has nothing to distinguish there.Configuration
📅 Schedule: (UTC)
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Mend Renovate CLI.