Skip to content

Conversation

@singhashish-wpf
Copy link
Contributor

@singhashish-wpf singhashish-wpf commented Feb 27, 2025

Microsoft Reviewers: Open in CodeFlow

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR Overview

This PR establishes code coverage reporting for WPF by introducing a new codecov configuration and integrating coverage reporting into the CI pipeline.

  • Added a codecov.yml configuration file with detailed coverage thresholds and flag definitions.
  • Updated README.md to include a codecov badge for production coverage.
  • Modified eng/pipeline-pr.yml to pass coverage parameters through build and test steps and to upload coverage data.

Reviewed Changes

File Description
codecov.yml New configuration for code coverage thresholds and flags.
README.md Added a codecov badge linking to coverage reports.
eng/pipeline-pr.yml Updated pipeline tasks to include coverage parameters and upload.

Copilot reviewed 12 out of 12 changed files in this pull request and generated 3 comments.

Comments suppressed due to low confidence (1)

codecov.yml:14

  • Verify that the pattern 'eng/::/' is correctly formatted for its intended purpose, as it may not match the desired paths.
    - "eng/::/"

@dotnet-policy-service dotnet-policy-service bot added the PR metadata: Label to tag PRs, to facilitate with triage label Feb 27, 2025
@codecov
Copy link

codecov bot commented Feb 27, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Please upload report for BASE (main@034ce35). Learn more about missing BASE report.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #10514   +/-   ##
==========================================
  Coverage        ?   10.99998%           
==========================================
  Files           ?        3215           
  Lines           ?      648474           
  Branches        ?       71534           
==========================================
  Hits            ?       71332           
  Misses          ?      576143           
  Partials        ?         999           
Flag Coverage Δ
Debug 10.99998% <100.00000%> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

@singhashish-wpf singhashish-wpf merged commit 7481b7e into main Feb 27, 2025
5 of 8 checks passed
@singhashish-wpf singhashish-wpf deleted the codecov branch February 27, 2025 12:11
'`' /*96*/, '|' /*124*/, '~' /*126*/,
];

private static ReadOnlySpan<char> AllowedCharacters => s_allowedCharacters;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why was this changed? Makes no sense?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep, just the same thing. This was done just to fix some test errors on CI:
https://dev.azure.com/dnceng-public/public/_build/results?buildId=964386&view=ms.vss-test-web.build-test-results-tab&runId=25692748&resultId=100633&paneView=debug

   at System.Runtime.CompilerServices.RuntimeHelpers.GetSpanDataFrom(RuntimeFieldHandle fldHandle, RuntimeTypeHandle targetTypeHandle, Int32& count)
   at System.Runtime.CompilerServices.RuntimeHelpers.CreateSpan[T](RuntimeFieldHandle fldHandle)
   at MS.Internal.ContentType.get_AllowedCharacters() in D:\a\_work\1\s\src\Microsoft.DotNet.Wpf\src\WindowsBase\MS\Internal\ContentType.cs:line 657
   at MS.Internal.ContentType.IsAllowedCharacter(Char character) in D:\a\_work\1\s\src\Microsoft.DotNet.Wpf\src\WindowsBase\MS\Internal\ContentType.cs:line 604

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@singhashish-wpf Yeah but that should never fail, it makes no sense why it should throw Argument_BadFieldForInitializeArray from GetSpanDataFrom.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Issue was in Coverlet, solved via #10625

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cool ! Thanks @h3xds1nz

h3xds1nz added a commit to h3xds1nz/wpf that referenced this pull request Mar 23, 2025
singhashish-wpf pushed a commit that referenced this pull request Mar 24, 2025
…10625)

* Update coverlet to newest version due to cecil RVA alignment fixes

* Revert changes done in #10514

* Use v6 because of coverlet#1726 (coverage.opencover.xml is empty)
@github-actions github-actions bot locked and limited conversation to collaborators Apr 24, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

PR metadata: Label to tag PRs, to facilitate with triage

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants