Skip to content

Introduce C++ SDK component type#1626

Merged
grvillic merged 1 commit intomainfrom
users/grvillic/AddCppComponentType
Feb 3, 2026
Merged

Introduce C++ SDK component type#1626
grvillic merged 1 commit intomainfrom
users/grvillic/AddCppComponentType

Conversation

@grvillic
Copy link
Collaborator

@grvillic grvillic commented Feb 3, 2026

We are experimenting with a new component type for C++ SDK version detection.

* Introduce C++ SDK component type
@codecov
Copy link

codecov bot commented Feb 3, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 90.2%. Comparing base (e2c9188) to head (40c55bf).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@          Coverage Diff          @@
##            main   #1626   +/-   ##
=====================================
  Coverage   90.2%   90.2%           
=====================================
  Files        437     439    +2     
  Lines      37801   37875   +74     
  Branches    2324    2331    +7     
=====================================
+ Hits       34121   34195   +74     
  Misses      3203    3203           
  Partials     477     477           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link

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.

Pull request overview

This PR introduces a new CppSdk component type to support C++ SDK version detection. This is an experimental feature to expand Component Detection's capability to detect C++ SDK dependencies.

Changes:

  • Added ComponentType.CppSdk enum value (20) to the component type enumeration
  • Implemented CppSdkComponent class following established TypedComponent patterns with Name and Version properties
  • Registered the new component type in TypedComponentMapping for serialization support
  • Added comprehensive unit tests for CppSdkComponent covering constructor validation and PackageUrl generation
  • Added serialization/deserialization test in TypedComponentSerializationTests

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/Microsoft.ComponentDetection.Contracts/TypedComponent/ComponentType.cs Adds CppSdk enum value (20) to the ComponentType enumeration
src/Microsoft.ComponentDetection.Contracts/TypedComponent/CppSdkComponent.cs Implements new CppSdkComponent class with Name/Version properties and PackageUrl generation using "generic" type with "cppsdk" qualifier
src/Microsoft.ComponentDetection.Contracts/BcdeModels/TypedComponentMapping.cs Registers CppSdkComponent in the type discriminator mapping for serialization support
test/Microsoft.ComponentDetection.Contracts.Tests/CppSdkComponentTests.cs Adds comprehensive unit tests for constructor validation, property initialization, and PackageUrl format
test/Microsoft.ComponentDetection.Contracts.Tests/TypedComponentSerializationTests.cs Adds serialization/deserialization test for CppSdkComponent

@grvillic grvillic merged commit 48571b6 into main Feb 3, 2026
35 of 36 checks passed
@grvillic grvillic deleted the users/grvillic/AddCppComponentType branch February 3, 2026 17:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants