Merge pull request #9666 from jwangyangls/fix-ut-warning

Fix a warning that appears when running the test
This commit is contained in:
jwangyangls 2019-10-31 15:37:21 +08:00 committed by GitHub
commit b0b63fdeae
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 2 deletions

View File

@ -8,7 +8,7 @@
[class.clr-form-compact-common]="!defaultTextsObj.isSystemDefaultQuota">
<clr-input-container>
<label class="left-label required" for="storage">{{ defaultTextsObj?.storageQuota | translate}}
<label class="left-label required" for="storage">{{ defaultTextsObj?.countQuota | translate}}
<clr-tooltip>
<clr-icon clrTooltipTrigger shape="info-circle" size="24"></clr-icon>
<clr-tooltip-content clrPosition="top-right" clrSize="lg" *clrIfOpen>
@ -33,7 +33,7 @@
</clr-input-container>
<clr-input-container>
<label for="count" class="left-label required">{{ defaultTextsObj.countQuota | translate}}
<label for="count" class="left-label required">{{ defaultTextsObj.storageQuota | translate}}
<clr-tooltip>
<clr-icon clrTooltipTrigger shape="info-circle" size="24"></clr-icon>
<clr-tooltip-content clrPosition="top-right" clrSize="lg" *clrIfOpen>

View File

@ -201,6 +201,8 @@ describe('ImmutableTagComponent', () => {
cloneRule.tag_selectors[0].pattern = 'rep';
let cloneRuleNoId = clone(mockRules[0]);
cloneRuleNoId.id = null;
let cloneDisableRule = clone(mockRules[0]);
cloneDisableRule.disabled = true;
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ImmutableTagComponent, AddRuleComponent, InlineAlertComponent],
@ -265,6 +267,8 @@ describe('ImmutableTagComponent', () => {
.withArgs(component.projectId, mockRules[0])
.and.returnValue(of(null))
.withArgs(component.projectId, cloneRule)
.and.returnValue(of(null))
.withArgs(component.projectId, cloneDisableRule)
.and.returnValue(of(null));
spyOn(immutableTagService, "deleteRule")
.withArgs(component.projectId, mockRules[3].id)