mirror of
https://github.com/goharbor/harbor.git
synced 2025-02-21 14:21:36 +01:00
Fixes-20537 SBOM tab should not exist when the artifact is helm package (#20539)
Fixes-20537 SBOM tab should not exist when the artifact is helm package #20538 Signed-off-by: xuelichao <xuel@vmware.com>
This commit is contained in:
parent
2b271701b0
commit
81fcc0a4eb
@ -59,7 +59,10 @@ export class ArtifactAdditionsComponent implements AfterViewChecked, OnInit {
|
|||||||
}
|
}
|
||||||
|
|
||||||
hasScannerSupportSBOM(): boolean {
|
hasScannerSupportSBOM(): boolean {
|
||||||
return this.artifactListPageService.hasScannerSupportSBOM();
|
if (this.additionLinks && this.additionLinks[ADDITIONS.SBOMS]) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
getVulnerability(): AdditionLink {
|
getVulnerability(): AdditionLink {
|
||||||
|
@ -179,8 +179,8 @@ describe('ResultSbomComponent (inline template)', () => {
|
|||||||
component.artifactDigest = mockedSbomDigest;
|
component.artifactDigest = mockedSbomDigest;
|
||||||
component.sbomDigest = mockedSbomDigest;
|
component.sbomDigest = mockedSbomDigest;
|
||||||
component.accessories = mockedAccessories;
|
component.accessories = mockedAccessories;
|
||||||
|
fixture.detectChanges();
|
||||||
fixture.whenStable().then(() => {
|
fixture.whenStable().then(() => {
|
||||||
fixture.detectChanges();
|
|
||||||
const el: HTMLElement =
|
const el: HTMLElement =
|
||||||
fixture.nativeElement.querySelector('.tip-block');
|
fixture.nativeElement.querySelector('.tip-block');
|
||||||
expect(el).not.toBeNull();
|
expect(el).not.toBeNull();
|
||||||
|
Loading…
Reference in New Issue
Block a user