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