chore: fix lint error (#8136)

Fixes a few linting errors
This commit is contained in:
Kristiyan Kostadinov
2017-10-30 23:12:50 +01:00
committed by mmalerba
parent f6b80f4358
commit b39202ff3f
3 changed files with 7 additions and 7 deletions
+1 -1
View File
@@ -245,7 +245,7 @@ export abstract class DateAdapter<D> {
let firstValid = this.isValid(first);
let secondValid = this.isValid(second);
if (firstValid && secondValid) {
return !this.compareDate(first, second)
return !this.compareDate(first, second);
}
return firstValid == secondValid;
}
@@ -18,15 +18,15 @@ describe('NativeDateAdapter', () => {
}).compileComponents();
}));
beforeEach(inject([DateAdapter], (d: NativeDateAdapter) => {
adapter = d;
beforeEach(inject([DateAdapter], (dateAdapter: NativeDateAdapter) => {
adapter = dateAdapter;
assertValidDate = (d: Date | null, valid: boolean) => {
expect(adapter.isDateInstance(d)).not.toBeNull(`Expected ${d} to be a date instance`);
expect(adapter.isValid(d!)).toBe(valid,
`Expected ${d} to be ${valid ? 'valid' : 'invalid'},` +
` but was ${valid ? 'invalid' : 'valid'}`);
}
};
}));
it('should get year', () => {
@@ -24,9 +24,9 @@ describe('MomentDateAdapter', () => {
}).compileComponents();
}));
beforeEach(inject([DateAdapter], (d: MomentDateAdapter) => {
beforeEach(inject([DateAdapter], (dateAdapter: MomentDateAdapter) => {
moment.locale('en');
adapter = d;
adapter = dateAdapter;
adapter.setLocale('en');
assertValidDate = (d: moment.Moment | null, valid: boolean) => {
@@ -34,7 +34,7 @@ describe('MomentDateAdapter', () => {
expect(adapter.isValid(d!)).toBe(valid,
`Expected ${d} to be ${valid ? 'valid' : 'invalid'},` +
` but was ${valid ? 'invalid' : 'valid'}`);
}
};
}));
it('should get year', () => {