Coder Social home page Coder Social logo

Comments (2)

rohanwayachal avatar rohanwayachal commented on September 23, 2024

image

from azure-pipelines-tasks.

joshua4163 avatar joshua4163 commented on September 23, 2024

It appears that after running a multitarget build and test, the code coverage for .NET Framework 4.6.2 (net462) is not being published. Let's troubleshoot this issue.

  1. Check Output Folder: Ensure that the output folder for your test results and code coverage reports is correctly specified. In your VSTest tasks, you're using $(System.DefaultWorkingDirectory)\out\$(BuildConfiguration) as the search folder. Confirm that the test results and coverage files are indeed generated in this location.

  2. Verify Test Assembly Path: In the VSTest tasks, you've specified the test assembly pattern for both .NET 6 and .NET Framework 4.6.2. Make sure that the wildcard pattern **\net462\Tests\Async.Bridges.*Tests.dll matches the actual location of your test assemblies. Double-check the path and ensure that the test DLLs are present in the expected directory.

  3. Code Coverage Settings: Ensure that your runSettingsFile (located at src/Default.runsettings) includes the necessary configuration for code coverage. Specifically, check if the <DataCollector> section includes the CodeCoverage data collector. If not, add it to the run settings file.

  4. Permissions and Access: Verify that the build agent or self-hosted environment has the necessary permissions to read/write files in the specified output folder. Sometimes issues arise due to insufficient permissions.

  5. Logging and Diagnostics: Enable detailed logging and diagnostics for the VSTest tasks. Set diagnosticsEnabled: true to get more information about what's happening during the test execution. Review the logs for any relevant error messages or warnings related to code coverage.

  6. Rerun Failed Tests: You've configured the tasks to rerun failed tests (rerunFailedTests: true). If any tests fail during the initial run, they will be retried. Check if any tests are consistently failing and investigate why.

  7. Thresholds and Minimum Expected Tests: You've set thresholds for rerunning failed tests (rerunFailedThreshold) and specified a minimum expected test count (minimumExpectedTests). Ensure that these values align with your expectations. If the minimum expected tests are not met, the build may fail.

  8. Missing Value for rerunFailedThreshold: It seems there's a missing value for rerunFailedThreshold in your configuration. Please provide the appropriate value (e.g., 20 as shown in your .NET 6 task).

from azure-pipelines-tasks.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.