microsoft / mu_basecore

Project Mu BaseCore
https://microsoft.github.io/mu/
Other
242 stars 124 forks source link

MdePkg: Create Google Test mock library and protocol #1152

Closed v-chhsieh closed 1 week ago

v-chhsieh commented 3 weeks ago

Description

This patch creates a gmock for the MpService function, which is used by CI testing.

For details on how to complete to complete these options and their meaning refer to CONTRIBUTING.md.

How This Was Tested

Unit tests component can call these mock functions success

Integration Instructions

N/A

codecov-commenter commented 3 weeks ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 1.59%. Comparing base (5724e5f) to head (b3bdc3d).

Additional details and impacted files ```diff @@ Coverage Diff @@ ## release/202405 #1152 +/- ## =============================================== Coverage 1.59% 1.59% =============================================== Files 1448 1448 Lines 362500 362500 Branches 5632 5632 =============================================== Hits 5776 5776 Misses 356617 356617 Partials 107 107 ``` | [Flag](https://app.codecov.io/gh/microsoft/mu_basecore/pull/1152/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=microsoft) | Coverage Δ | | |---|---|---| | [MdeModulePkg](https://app.codecov.io/gh/microsoft/mu_basecore/pull/1152/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=microsoft) | `0.68% <ø> (ø)` | | | [MdePkg](https://app.codecov.io/gh/microsoft/mu_basecore/pull/1152/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=microsoft) | `5.42% <ø> (ø)` | | | [NetworkPkg](https://app.codecov.io/gh/microsoft/mu_basecore/pull/1152/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=microsoft) | `0.55% <ø> (ø)` | | | [PolicyServicePkg](https://app.codecov.io/gh/microsoft/mu_basecore/pull/1152/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=microsoft) | `30.41% <ø> (ø)` | | | [UefiCpuPkg](https://app.codecov.io/gh/microsoft/mu_basecore/pull/1152/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=microsoft) | `4.73% <ø> (ø)` | | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=microsoft#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

v-chhsieh commented 3 weeks ago

@microsoft-github-policy-service agree company="Phoenix"

os-d commented 3 weeks ago

@v-chhsieh, can you take this PR directly to edk2? They have a PR process now and we are updating our process to take as many PRs directly to edk2 (if it makes sense) and then will cherry-pick them back into Project Mu. This will have less churn on the consumer if edk2 wants changes in the PR, etc., the consumer of Project Mu won't have to make changes

v-chhsieh commented 3 weeks ago

@v-chhsieh, can you take this PR directly to edk2? They have a PR process now and we are updating our process to take as many PRs directly to edk2 (if it makes sense) and then will cherry-pick them back into Project Mu. This will have less churn on the consumer if edk2 wants changes in the PR, etc., the consumer of Project Mu won't have to make changes

Yes, no problem.

v-chhsieh commented 2 weeks ago

I am working to collect and update the other mock for this PR, so I don't need to submit another mock PR again.