* [PATCH v2 1/2] BaseTools/Plugin: Report error if code coverage failure @ 2023-04-23 1:22 Guo, Gua 2023-04-23 1:22 ` [PATCH v2 2/2] .azurepipelines: Install code coverage tool Guo, Gua 2023-04-23 3:13 ` [PATCH v2 1/2] BaseTools/Plugin: Report error if code coverage failure Michael D Kinney 0 siblings, 2 replies; 8+ messages in thread From: Guo, Gua @ 2023-04-23 1:22 UTC (permalink / raw) To: devel; +Cc: Gua Guo, Michael D Kinney, Sean Brogan, Michael Kubacki From: Gua Guo <gua.guo@intel.com> If code coverage exist failure, CI/CD need to catch it Cc: Michael D Kinney <michael.d.kinney@intel.com> Cc: Sean Brogan <sean.brogan@microsoft.com> Cc: Michael Kubacki <mikuback@linux.microsoft.com> Signed-off-by: Gua Guo <gua.guo@intel.com> --- .../HostBasedUnitTestRunner/HostBasedUnitTestRunner.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/BaseTools/Plugin/HostBasedUnitTestRunner/HostBasedUnitTestRunner.py b/BaseTools/Plugin/HostBasedUnitTestRunner/HostBasedUnitTestRunner.py index 0e013c5f1a..86b6bd36df 100644 --- a/BaseTools/Plugin/HostBasedUnitTestRunner/HostBasedUnitTestRunner.py +++ b/BaseTools/Plugin/HostBasedUnitTestRunner/HostBasedUnitTestRunner.py @@ -117,9 +117,13 @@ class HostBasedUnitTestRunner(IUefiBuildPlugin): if thebuilder.env.GetValue("CODE_COVERAGE") != "FALSE": if thebuilder.env.GetValue("TOOL_CHAIN_TAG") == "GCC5": - self.gen_code_coverage_gcc(thebuilder) + ret = self.gen_code_coverage_gcc(thebuilder) + if ret != 0: + failure_count += 1 elif thebuilder.env.GetValue("TOOL_CHAIN_TAG").startswith ("VS"): - self.gen_code_coverage_msvc(thebuilder) + ret = self.gen_code_coverage_msvc(thebuilder) + if ret != 0: + failure_count += 1 else: logging.info("Skipping code coverage. Currently, support GCC and MSVC compiler.") -- 2.39.2.windows.1 ^ permalink raw reply related [flat|nested] 8+ messages in thread
* [PATCH v2 2/2] .azurepipelines: Install code coverage tool 2023-04-23 1:22 [PATCH v2 1/2] BaseTools/Plugin: Report error if code coverage failure Guo, Gua @ 2023-04-23 1:22 ` Guo, Gua 2023-04-23 3:15 ` Michael D Kinney 2023-04-23 3:13 ` [PATCH v2 1/2] BaseTools/Plugin: Report error if code coverage failure Michael D Kinney 1 sibling, 1 reply; 8+ messages in thread From: Guo, Gua @ 2023-04-23 1:22 UTC (permalink / raw) To: devel Cc: Gua Guo, Michael D Kinney, Sean Brogan, Michael Kubacki, Oliver Steffen From: Gua Guo <gua.guo@intel.com> Azure should install code coverage tool (lcov), it didn't exist on Fedora and Ubuntu by default. Cc: Michael D Kinney <michael.d.kinney@intel.com> Cc: Sean Brogan <sean.brogan@microsoft.com> Cc: Michael Kubacki <mikuback@linux.microsoft.com> Cc: Oliver Steffen <osteffen@redhat.com> Signed-off-by: Gua Guo <gua.guo@intel.com> --- .azurepipelines/Ubuntu-GCC5.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.azurepipelines/Ubuntu-GCC5.yml b/.azurepipelines/Ubuntu-GCC5.yml index b9a3b851cf..d884256148 100644 --- a/.azurepipelines/Ubuntu-GCC5.yml +++ b/.azurepipelines/Ubuntu-GCC5.yml @@ -24,3 +24,7 @@ jobs: container: ${{ variables.default_linux_image }} arch_list: "IA32,X64,ARM,AARCH64,RISCV64,LOONGARCH64" usePythonVersion: '' # use Python from the container image + extra_install_step: + - bash: sudo dnf install -y lcov + displayName: Install Code Coverage Tools + condition: and(gt(variables.pkg_count, 0), succeeded()) -- 2.39.2.windows.1 ^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH v2 2/2] .azurepipelines: Install code coverage tool 2023-04-23 1:22 ` [PATCH v2 2/2] .azurepipelines: Install code coverage tool Guo, Gua @ 2023-04-23 3:15 ` Michael D Kinney 2023-04-23 6:13 ` [edk2-devel] " Sean 0 siblings, 1 reply; 8+ messages in thread From: Michael D Kinney @ 2023-04-23 3:15 UTC (permalink / raw) To: Guo, Gua, devel@edk2.groups.io Cc: Sean Brogan, Michael Kubacki, Oliver Steffen, Kinney, Michael D Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com> > -----Original Message----- > From: Guo, Gua <gua.guo@intel.com> > Sent: Saturday, April 22, 2023 6:22 PM > To: devel@edk2.groups.io > Cc: Guo, Gua <gua.guo@intel.com>; Kinney, Michael D <michael.d.kinney@intel.com>; Sean Brogan <sean.brogan@microsoft.com>; > Michael Kubacki <mikuback@linux.microsoft.com>; Oliver Steffen <osteffen@redhat.com> > Subject: [PATCH v2 2/2] .azurepipelines: Install code coverage tool > > From: Gua Guo <gua.guo@intel.com> > > Azure should install code coverage tool (lcov), it didn't > exist on Fedora and Ubuntu by default. > > Cc: Michael D Kinney <michael.d.kinney@intel.com> > Cc: Sean Brogan <sean.brogan@microsoft.com> > Cc: Michael Kubacki <mikuback@linux.microsoft.com> > Cc: Oliver Steffen <osteffen@redhat.com> > Signed-off-by: Gua Guo <gua.guo@intel.com> > --- > .azurepipelines/Ubuntu-GCC5.yml | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/.azurepipelines/Ubuntu-GCC5.yml b/.azurepipelines/Ubuntu-GCC5.yml > index b9a3b851cf..d884256148 100644 > --- a/.azurepipelines/Ubuntu-GCC5.yml > +++ b/.azurepipelines/Ubuntu-GCC5.yml > @@ -24,3 +24,7 @@ jobs: > container: ${{ variables.default_linux_image }} > > arch_list: "IA32,X64,ARM,AARCH64,RISCV64,LOONGARCH64" > > usePythonVersion: '' # use Python from the container image > > + extra_install_step: > > + - bash: sudo dnf install -y lcov > > + displayName: Install Code Coverage Tools > > + condition: and(gt(variables.pkg_count, 0), succeeded()) > > -- > 2.39.2.windows.1 ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [edk2-devel] [PATCH v2 2/2] .azurepipelines: Install code coverage tool 2023-04-23 3:15 ` Michael D Kinney @ 2023-04-23 6:13 ` Sean 2023-04-23 8:44 ` Guo, Gua 0 siblings, 1 reply; 8+ messages in thread From: Sean @ 2023-04-23 6:13 UTC (permalink / raw) To: devel@edk2.groups.io, michael.d.kinney@intel.com, Guo, Gua, Chris Fernald Cc: Sean Brogan, Michael Kubacki, Oliver Steffen, Kinney, Michael D [-- Attachment #1: Type: text/plain, Size: 2493 bytes --] Sorry a little late to review this. It looks like these are container based builds. If that is the case we should handle this by updating the container. The whole point of the container is to get the requirements all included in the container. @Chris Fernald<mailto:chfernal@microsoft.com> can you share details. Thanks Sean ________________________________ From: devel@edk2.groups.io <devel@edk2.groups.io> on behalf of Michael D Kinney <michael.d.kinney@intel.com> Sent: Saturday, April 22, 2023 8:15:56 PM To: Guo, Gua <gua.guo@intel.com>; devel@edk2.groups.io <devel@edk2.groups.io> Cc: Sean Brogan <sean.brogan@microsoft.com>; Michael Kubacki <mikuback@linux.microsoft.com>; Oliver Steffen <osteffen@redhat.com>; Kinney, Michael D <michael.d.kinney@intel.com> Subject: Re: [edk2-devel] [PATCH v2 2/2] .azurepipelines: Install code coverage tool Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com> > -----Original Message----- > From: Guo, Gua <gua.guo@intel.com> > Sent: Saturday, April 22, 2023 6:22 PM > To: devel@edk2.groups.io > Cc: Guo, Gua <gua.guo@intel.com>; Kinney, Michael D <michael.d.kinney@intel.com>; Sean Brogan <sean.brogan@microsoft.com>; > Michael Kubacki <mikuback@linux.microsoft.com>; Oliver Steffen <osteffen@redhat.com> > Subject: [PATCH v2 2/2] .azurepipelines: Install code coverage tool > > From: Gua Guo <gua.guo@intel.com> > > Azure should install code coverage tool (lcov), it didn't > exist on Fedora and Ubuntu by default. > > Cc: Michael D Kinney <michael.d.kinney@intel.com> > Cc: Sean Brogan <sean.brogan@microsoft.com> > Cc: Michael Kubacki <mikuback@linux.microsoft.com> > Cc: Oliver Steffen <osteffen@redhat.com> > Signed-off-by: Gua Guo <gua.guo@intel.com> > --- > .azurepipelines/Ubuntu-GCC5.yml | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/.azurepipelines/Ubuntu-GCC5.yml b/.azurepipelines/Ubuntu-GCC5.yml > index b9a3b851cf..d884256148 100644 > --- a/.azurepipelines/Ubuntu-GCC5.yml > +++ b/.azurepipelines/Ubuntu-GCC5.yml > @@ -24,3 +24,7 @@ jobs: > container: ${{ variables.default_linux_image }} > > arch_list: "IA32,X64,ARM,AARCH64,RISCV64,LOONGARCH64" > > usePythonVersion: '' # use Python from the container image > > + extra_install_step: > > + - bash: sudo dnf install -y lcov > > + displayName: Install Code Coverage Tools > > + condition: and(gt(variables.pkg_count, 0), succeeded()) > > -- > 2.39.2.windows.1 [-- Attachment #2: Type: text/html, Size: 3882 bytes --] ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [edk2-devel] [PATCH v2 2/2] .azurepipelines: Install code coverage tool 2023-04-23 6:13 ` [edk2-devel] " Sean @ 2023-04-23 8:44 ` Guo, Gua 2023-04-23 16:45 ` Michael D Kinney 2023-04-24 1:56 ` Guo, Gua 0 siblings, 2 replies; 8+ messages in thread From: Guo, Gua @ 2023-04-23 8:44 UTC (permalink / raw) To: devel@edk2.groups.io, Kinney, Michael D, fernald, chris Cc: Sean Brogan, Michael Kubacki, Oliver Steffen, Kinney, Michael D [-- Attachment #1: Type: text/plain, Size: 3326 bytes --] I know maybe I need to update https://github.com/tianocore/containers but add these step, i f have any guidelines for me that will be great. ________________________________ 寄件者: 「devel@edk2.groups.io <devel@edk2.groups.io>」代表「Sean <spbrogan@outlook.com>」 寄件日期: 2023年4月23日 星期日 下午2:13 收件者: devel@edk2.groups.io <devel@edk2.groups.io>; Kinney, Michael D <michael.d.kinney@intel.com>; Guo, Gua <gua.guo@intel.com>; fernald, chris <chfernal@microsoft.com> 副本: Sean Brogan <sean.brogan@microsoft.com>; Michael Kubacki <mikuback@linux.microsoft.com>; Oliver Steffen <osteffen@redhat.com>; Kinney, Michael D <michael.d.kinney@intel.com> 主旨: Re: [edk2-devel] [PATCH v2 2/2] .azurepipelines: Install code coverage tool Sorry a little late to review this. It looks like these are container based builds. If that is the case we should handle this by updating the container. The whole point of the container is to get the requirements all included in the container. @Chris Fernald<mailto:chfernal@microsoft.com> can you share details. Thanks Sean ________________________________ From: devel@edk2.groups.io <devel@edk2.groups.io> on behalf of Michael D Kinney <michael.d.kinney@intel.com> Sent: Saturday, April 22, 2023 8:15:56 PM To: Guo, Gua <gua.guo@intel.com>; devel@edk2.groups.io <devel@edk2.groups.io> Cc: Sean Brogan <sean.brogan@microsoft.com>; Michael Kubacki <mikuback@linux.microsoft.com>; Oliver Steffen <osteffen@redhat.com>; Kinney, Michael D <michael.d.kinney@intel.com> Subject: Re: [edk2-devel] [PATCH v2 2/2] .azurepipelines: Install code coverage tool Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com> > -----Original Message----- > From: Guo, Gua <gua.guo@intel.com> > Sent: Saturday, April 22, 2023 6:22 PM > To: devel@edk2.groups.io > Cc: Guo, Gua <gua.guo@intel.com>; Kinney, Michael D <michael.d.kinney@intel.com>; Sean Brogan <sean.brogan@microsoft.com>; > Michael Kubacki <mikuback@linux.microsoft.com>; Oliver Steffen <osteffen@redhat.com> > Subject: [PATCH v2 2/2] .azurepipelines: Install code coverage tool > > From: Gua Guo <gua.guo@intel.com> > > Azure should install code coverage tool (lcov), it didn't > exist on Fedora and Ubuntu by default. > > Cc: Michael D Kinney <michael.d.kinney@intel.com> > Cc: Sean Brogan <sean.brogan@microsoft.com> > Cc: Michael Kubacki <mikuback@linux.microsoft.com> > Cc: Oliver Steffen <osteffen@redhat.com> > Signed-off-by: Gua Guo <gua.guo@intel.com> > --- > .azurepipelines/Ubuntu-GCC5.yml | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/.azurepipelines/Ubuntu-GCC5.yml b/.azurepipelines/Ubuntu-GCC5.yml > index b9a3b851cf..d884256148 100644 > --- a/.azurepipelines/Ubuntu-GCC5.yml > +++ b/.azurepipelines/Ubuntu-GCC5.yml > @@ -24,3 +24,7 @@ jobs: > container: ${{ variables.default_linux_image }} > > arch_list: "IA32,X64,ARM,AARCH64,RISCV64,LOONGARCH64" > > usePythonVersion: '' # use Python from the container image > > + extra_install_step: > > + - bash: sudo dnf install -y lcov > > + displayName: Install Code Coverage Tools > > + condition: and(gt(variables.pkg_count, 0), succeeded()) > > -- > 2.39.2.windows.1 [-- Attachment #2: Type: text/html, Size: 5186 bytes --] ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [edk2-devel] [PATCH v2 2/2] .azurepipelines: Install code coverage tool 2023-04-23 8:44 ` Guo, Gua @ 2023-04-23 16:45 ` Michael D Kinney 2023-04-24 1:56 ` Guo, Gua 1 sibling, 0 replies; 8+ messages in thread From: Michael D Kinney @ 2023-04-23 16:45 UTC (permalink / raw) To: Guo, Gua, devel@edk2.groups.io, fernald, chris Cc: Sean Brogan, Michael Kubacki, Oliver Steffen, Kinney, Michael D [-- Attachment #1: Type: text/plain, Size: 5081 bytes --] Hi Sean, I agree the container image needs to be updated. Is this also required for local developer runs of the stuart tools? Or should this be part of the setup that developers do before running stuart? Thanks, Mike From: Guo, Gua <gua.guo@intel.com> Sent: Sunday, April 23, 2023 1:44 AM To: devel@edk2.groups.io; Kinney, Michael D <michael.d.kinney@intel.com>; fernald, chris <chfernal@microsoft.com> Cc: Sean Brogan <sean.brogan@microsoft.com>; Michael Kubacki <mikuback@linux.microsoft.com>; Oliver Steffen <osteffen@redhat.com>; Kinney, Michael D <michael.d.kinney@intel.com> Subject: Re: [edk2-devel] [PATCH v2 2/2] .azurepipelines: Install code coverage tool I know maybe I need to update https://github.com/tianocore/containers but add these step, i f have any guidelines for me that will be great. ________________________________ 寄件者: 「devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>>」代表「Sean <spbrogan@outlook.com<mailto:spbrogan@outlook.com>>」 寄件日期: 2023年4月23日 星期日 下午2:13 收件者: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>>; Kinney, Michael D <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Guo, Gua <gua.guo@intel.com<mailto:gua.guo@intel.com>>; fernald, chris <chfernal@microsoft.com<mailto:chfernal@microsoft.com>> 副本: Sean Brogan <sean.brogan@microsoft.com<mailto:sean.brogan@microsoft.com>>; Michael Kubacki <mikuback@linux.microsoft.com<mailto:mikuback@linux.microsoft.com>>; Oliver Steffen <osteffen@redhat.com<mailto:osteffen@redhat.com>>; Kinney, Michael D <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>> 主旨: Re: [edk2-devel] [PATCH v2 2/2] .azurepipelines: Install code coverage tool Sorry a little late to review this. It looks like these are container based builds. If that is the case we should handle this by updating the container. The whole point of the container is to get the requirements all included in the container. @Chris Fernald<mailto:chfernal@microsoft.com> can you share details. Thanks Sean ________________________________ From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> on behalf of Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>> Sent: Saturday, April 22, 2023 8:15:56 PM To: Guo, Gua <gua.guo@intel.com<mailto:gua.guo@intel.com>>; devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> Cc: Sean Brogan <sean.brogan@microsoft.com<mailto:sean.brogan@microsoft.com>>; Michael Kubacki <mikuback@linux.microsoft.com<mailto:mikuback@linux.microsoft.com>>; Oliver Steffen <osteffen@redhat.com<mailto:osteffen@redhat.com>>; Kinney, Michael D <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>> Subject: Re: [edk2-devel] [PATCH v2 2/2] .azurepipelines: Install code coverage tool Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>> > -----Original Message----- > From: Guo, Gua <gua.guo@intel.com<mailto:gua.guo@intel.com>> > Sent: Saturday, April 22, 2023 6:22 PM > To: devel@edk2.groups.io<mailto:devel@edk2.groups.io> > Cc: Guo, Gua <gua.guo@intel.com<mailto:gua.guo@intel.com>>; Kinney, Michael D <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Sean Brogan <sean.brogan@microsoft.com<mailto:sean.brogan@microsoft.com>>; > Michael Kubacki <mikuback@linux.microsoft.com<mailto:mikuback@linux.microsoft.com>>; Oliver Steffen <osteffen@redhat.com<mailto:osteffen@redhat.com>> > Subject: [PATCH v2 2/2] .azurepipelines: Install code coverage tool > > From: Gua Guo <gua.guo@intel.com<mailto:gua.guo@intel.com>> > > Azure should install code coverage tool (lcov), it didn't > exist on Fedora and Ubuntu by default. > > Cc: Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>> > Cc: Sean Brogan <sean.brogan@microsoft.com<mailto:sean.brogan@microsoft.com>> > Cc: Michael Kubacki <mikuback@linux.microsoft.com<mailto:mikuback@linux.microsoft.com>> > Cc: Oliver Steffen <osteffen@redhat.com<mailto:osteffen@redhat.com>> > Signed-off-by: Gua Guo <gua.guo@intel.com<mailto:gua.guo@intel.com>> > --- > .azurepipelines/Ubuntu-GCC5.yml | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/.azurepipelines/Ubuntu-GCC5.yml b/.azurepipelines/Ubuntu-GCC5.yml > index b9a3b851cf..d884256148 100644 > --- a/.azurepipelines/Ubuntu-GCC5.yml > +++ b/.azurepipelines/Ubuntu-GCC5.yml > @@ -24,3 +24,7 @@ jobs: > container: ${{ variables.default_linux_image }} > > arch_list: "IA32,X64,ARM,AARCH64,RISCV64,LOONGARCH64" > > usePythonVersion: '' # use Python from the container image > > + extra_install_step: > > + - bash: sudo dnf install -y lcov > > + displayName: Install Code Coverage Tools > > + condition: and(gt(variables.pkg_count, 0), succeeded()) > > -- > 2.39.2.windows.1 [-- Attachment #2: Type: text/html, Size: 50282 bytes --] ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [edk2-devel] [PATCH v2 2/2] .azurepipelines: Install code coverage tool 2023-04-23 8:44 ` Guo, Gua 2023-04-23 16:45 ` Michael D Kinney @ 2023-04-24 1:56 ` Guo, Gua 1 sibling, 0 replies; 8+ messages in thread From: Guo, Gua @ 2023-04-24 1:56 UTC (permalink / raw) To: devel@edk2.groups.io, Kinney, Michael D, fernald, chris Cc: Sean Brogan, Michael Kubacki, Oliver Steffen, Kinney, Michael D [-- Attachment #1: Type: text/plain, Size: 5385 bytes --] In parallel, I’ve sent the PR Install lcov in all linux based image by gguo11837463 * Pull Request #70 * tianocore/containers (github.com)<https://github.com/tianocore/containers/pull/70> to https://github.com/tianocore/containers, if the PR looks good and deploy into latest images that can be used by latest Edk2 azurepipeline. I can revert commit “ba3afb0d474241e26442dd4ccf45c81d03a4c50e” on the PR https://github.com/tianocore/edk2/pull/4300. Thanks, Gua From: Guo, Gua <gua.guo@intel.com> Sent: Sunday, April 23, 2023 4:44 PM To: devel@edk2.groups.io; Kinney, Michael D <michael.d.kinney@intel.com>; fernald, chris <chfernal@microsoft.com> Cc: Sean Brogan <sean.brogan@microsoft.com>; Michael Kubacki <mikuback@linux.microsoft.com>; Oliver Steffen <osteffen@redhat.com>; Kinney, Michael D <michael.d.kinney@intel.com> Subject: Re: [edk2-devel] [PATCH v2 2/2] .azurepipelines: Install code coverage tool I know maybe I need to update https://github.com/tianocore/containers but add these step, i f have any guidelines for me that will be great. ________________________________ 寄件者: 「devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>>」代表「Sean <spbrogan@outlook.com<mailto:spbrogan@outlook.com>>」 寄件日期: 2023年4月23日 星期日 下午2:13 收件者: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>>; Kinney, Michael D <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Guo, Gua <gua.guo@intel.com<mailto:gua.guo@intel.com>>; fernald, chris <chfernal@microsoft.com<mailto:chfernal@microsoft.com>> 副本: Sean Brogan <sean.brogan@microsoft.com<mailto:sean.brogan@microsoft.com>>; Michael Kubacki <mikuback@linux.microsoft.com<mailto:mikuback@linux.microsoft.com>>; Oliver Steffen <osteffen@redhat.com<mailto:osteffen@redhat.com>>; Kinney, Michael D <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>> 主旨: Re: [edk2-devel] [PATCH v2 2/2] .azurepipelines: Install code coverage tool Sorry a little late to review this. It looks like these are container based builds. If that is the case we should handle this by updating the container. The whole point of the container is to get the requirements all included in the container. @Chris Fernald<mailto:chfernal@microsoft.com> can you share details. Thanks Sean ________________________________ From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> on behalf of Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>> Sent: Saturday, April 22, 2023 8:15:56 PM To: Guo, Gua <gua.guo@intel.com<mailto:gua.guo@intel.com>>; devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> Cc: Sean Brogan <sean.brogan@microsoft.com<mailto:sean.brogan@microsoft.com>>; Michael Kubacki <mikuback@linux.microsoft.com<mailto:mikuback@linux.microsoft.com>>; Oliver Steffen <osteffen@redhat.com<mailto:osteffen@redhat.com>>; Kinney, Michael D <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>> Subject: Re: [edk2-devel] [PATCH v2 2/2] .azurepipelines: Install code coverage tool Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>> > -----Original Message----- > From: Guo, Gua <gua.guo@intel.com<mailto:gua.guo@intel.com>> > Sent: Saturday, April 22, 2023 6:22 PM > To: devel@edk2.groups.io<mailto:devel@edk2.groups.io> > Cc: Guo, Gua <gua.guo@intel.com<mailto:gua.guo@intel.com>>; Kinney, Michael D <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Sean Brogan <sean.brogan@microsoft.com<mailto:sean.brogan@microsoft.com>>; > Michael Kubacki <mikuback@linux.microsoft.com<mailto:mikuback@linux.microsoft.com>>; Oliver Steffen <osteffen@redhat.com<mailto:osteffen@redhat.com>> > Subject: [PATCH v2 2/2] .azurepipelines: Install code coverage tool > > From: Gua Guo <gua.guo@intel.com<mailto:gua.guo@intel.com>> > > Azure should install code coverage tool (lcov), it didn't > exist on Fedora and Ubuntu by default. > > Cc: Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>> > Cc: Sean Brogan <sean.brogan@microsoft.com<mailto:sean.brogan@microsoft.com>> > Cc: Michael Kubacki <mikuback@linux.microsoft.com<mailto:mikuback@linux.microsoft.com>> > Cc: Oliver Steffen <osteffen@redhat.com<mailto:osteffen@redhat.com>> > Signed-off-by: Gua Guo <gua.guo@intel.com<mailto:gua.guo@intel.com>> > --- > .azurepipelines/Ubuntu-GCC5.yml | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/.azurepipelines/Ubuntu-GCC5.yml b/.azurepipelines/Ubuntu-GCC5.yml > index b9a3b851cf..d884256148 100644 > --- a/.azurepipelines/Ubuntu-GCC5.yml > +++ b/.azurepipelines/Ubuntu-GCC5.yml > @@ -24,3 +24,7 @@ jobs: > container: ${{ variables.default_linux_image }} > > arch_list: "IA32,X64,ARM,AARCH64,RISCV64,LOONGARCH64" > > usePythonVersion: '' # use Python from the container image > > + extra_install_step: > > + - bash: sudo dnf install -y lcov > > + displayName: Install Code Coverage Tools > > + condition: and(gt(variables.pkg_count, 0), succeeded()) > > -- > 2.39.2.windows.1 [-- Attachment #2: Type: text/html, Size: 12571 bytes --] ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH v2 1/2] BaseTools/Plugin: Report error if code coverage failure 2023-04-23 1:22 [PATCH v2 1/2] BaseTools/Plugin: Report error if code coverage failure Guo, Gua 2023-04-23 1:22 ` [PATCH v2 2/2] .azurepipelines: Install code coverage tool Guo, Gua @ 2023-04-23 3:13 ` Michael D Kinney 1 sibling, 0 replies; 8+ messages in thread From: Michael D Kinney @ 2023-04-23 3:13 UTC (permalink / raw) To: Guo, Gua, devel@edk2.groups.io Cc: Sean Brogan, Michael Kubacki, Kinney, Michael D Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com> > -----Original Message----- > From: Guo, Gua <gua.guo@intel.com> > Sent: Saturday, April 22, 2023 6:22 PM > To: devel@edk2.groups.io > Cc: Guo, Gua <gua.guo@intel.com>; Kinney, Michael D <michael.d.kinney@intel.com>; Sean Brogan <sean.brogan@microsoft.com>; > Michael Kubacki <mikuback@linux.microsoft.com> > Subject: [PATCH v2 1/2] BaseTools/Plugin: Report error if code coverage failure > > From: Gua Guo <gua.guo@intel.com> > > If code coverage exist failure, CI/CD need to catch it > > Cc: Michael D Kinney <michael.d.kinney@intel.com> > Cc: Sean Brogan <sean.brogan@microsoft.com> > Cc: Michael Kubacki <mikuback@linux.microsoft.com> > Signed-off-by: Gua Guo <gua.guo@intel.com> > --- > .../HostBasedUnitTestRunner/HostBasedUnitTestRunner.py | 8 ++++++-- > 1 file changed, 6 insertions(+), 2 deletions(-) > > diff --git a/BaseTools/Plugin/HostBasedUnitTestRunner/HostBasedUnitTestRunner.py > b/BaseTools/Plugin/HostBasedUnitTestRunner/HostBasedUnitTestRunner.py > index 0e013c5f1a..86b6bd36df 100644 > --- a/BaseTools/Plugin/HostBasedUnitTestRunner/HostBasedUnitTestRunner.py > +++ b/BaseTools/Plugin/HostBasedUnitTestRunner/HostBasedUnitTestRunner.py > @@ -117,9 +117,13 @@ class HostBasedUnitTestRunner(IUefiBuildPlugin): > > > if thebuilder.env.GetValue("CODE_COVERAGE") != "FALSE": > > if thebuilder.env.GetValue("TOOL_CHAIN_TAG") == "GCC5": > > - self.gen_code_coverage_gcc(thebuilder) > > + ret = self.gen_code_coverage_gcc(thebuilder) > > + if ret != 0: > > + failure_count += 1 > > elif thebuilder.env.GetValue("TOOL_CHAIN_TAG").startswith ("VS"): > > - self.gen_code_coverage_msvc(thebuilder) > > + ret = self.gen_code_coverage_msvc(thebuilder) > > + if ret != 0: > > + failure_count += 1 > > else: > > logging.info("Skipping code coverage. Currently, support GCC and MSVC compiler.") > > > > -- > 2.39.2.windows.1 ^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2023-04-24 1:56 UTC | newest] Thread overview: 8+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2023-04-23 1:22 [PATCH v2 1/2] BaseTools/Plugin: Report error if code coverage failure Guo, Gua 2023-04-23 1:22 ` [PATCH v2 2/2] .azurepipelines: Install code coverage tool Guo, Gua 2023-04-23 3:15 ` Michael D Kinney 2023-04-23 6:13 ` [edk2-devel] " Sean 2023-04-23 8:44 ` Guo, Gua 2023-04-23 16:45 ` Michael D Kinney 2023-04-24 1:56 ` Guo, Gua 2023-04-23 3:13 ` [PATCH v2 1/2] BaseTools/Plugin: Report error if code coverage failure Michael D Kinney
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox