-
Notifications
You must be signed in to change notification settings - Fork 24
FEAT: Full Stack Code Coverage #238
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
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR introduces a comprehensive code coverage solution for the mssql-python project, enabling unified Python and C++ coverage reporting on macOS through GitHub Actions. The implementation adds automated coverage collection, merging, and PR commenting capabilities.
- Adds a new GitHub Actions workflow for macOS-based unified coverage testing on pull requests
- Implements a shell script to automate coverage collection, merging Python and C++ coverage data
- Updates the CMake build configuration to enable Clang coverage instrumentation on macOS
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 4 comments.
File | Description |
---|---|
.github/workflows/pr-code-coverage.yml |
New GitHub Actions workflow for running tests and generating unified coverage reports on macOS |
generate_codecov.sh |
New script to collect, merge, and generate HTML coverage reports from Python and C++ code |
mssql_python/pybind/build.sh |
Updated to include Clang coverage flags for C++ instrumentation on macOS |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
…ain permissions Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
… bewithgaurav/universal_codecov
✅ Azure DevOps build completed successfully. |
📊 Code Coverage Report
📋 Files Needing Attention📉 Files with lowest coverage (click to expand)mssql_python.pybind.ddbc_bindings.cpp: 62.1%
mssql_python.ddbc_bindings.py: 68.5%
mssql_python.pybind.connection.connection_pool.cpp: 78.9%
mssql_python.helpers.py: 84.7%
mssql_python.auth.py: 85.3%
🔗 Quick Links
🤖 This report was automatically generated from Azure DevOps build artifacts |
… bewithgaurav/universal_codecov
… bewithgaurav/universal_codecov
Work Item / Issue Reference
Summary
This pull request introduces a new workflow for unified code coverage on macOS, enabling combined Python and C++ coverage reports for pull requests. It adds a new GitHub Actions workflow, a coverage generation script, and updates the CMake build configuration to support Clang coverage instrumentation.
CI/CD and Coverage Reporting Improvements:
.github/workflows/pr-code-coverage.yml
to run tests on macOS, build C++ bindings, start a SQL Server container, and generate a unified (Python + C++) coverage report, which is automatically commented on pull requests.generate_codecov.sh
script to automate the process of collecting, merging, and generating unified HTML coverage reports from both Python and C++ code using LLVM, lcov, and coverage-lcov.Build System Updates:
mssql_python/pybind/build.sh
to configure CMake with Clang coverage instrumentation flags (-fprofile-instr-generate -fcoverage-mapping
) on macOS, enabling C++ code coverage collection.