Prettier upgrade and e2e type checks (#1522)

* upgrade prettier

* noImplicitAny rule

* fix type

* update tsconfig

* upgrade to 150 print width
This commit is contained in:
Denys Vuika
2020-07-14 10:03:23 +01:00
committed by GitHub
parent 32793ea7b0
commit ddc6f36ab4
339 changed files with 5170 additions and 8763 deletions

View File

@@ -23,20 +23,9 @@
* along with Alfresco. If not, see <http://www.gnu.org/licenses/>.
*/
import {
TestBed,
ComponentFixture,
fakeAsync,
tick
} from '@angular/core/testing';
import { TestBed, ComponentFixture, fakeAsync, tick } from '@angular/core/testing';
import { NO_ERRORS_SCHEMA } from '@angular/core';
import {
AlfrescoApiService,
NodeFavoriteDirective,
DataTableComponent,
AppConfigPipe,
UploadService
} from '@alfresco/adf-core';
import { AlfrescoApiService, NodeFavoriteDirective, DataTableComponent, AppConfigPipe, UploadService } from '@alfresco/adf-core';
import { DocumentListComponent } from '@alfresco/adf-content-services';
import { RecentFilesComponent } from './recent-files.component';
import { AppTestingModule } from '../../testing/app-testing.module';
@@ -65,13 +54,7 @@ describe('RecentFilesComponent', () => {
beforeEach(() => {
TestBed.configureTestingModule({
imports: [AppTestingModule],
declarations: [
DataTableComponent,
NodeFavoriteDirective,
DocumentListComponent,
RecentFilesComponent,
AppConfigPipe
],
declarations: [DataTableComponent, NodeFavoriteDirective, DocumentListComponent, RecentFilesComponent, AppConfigPipe],
providers: [
{
provide: Router,
@@ -94,9 +77,7 @@ describe('RecentFilesComponent', () => {
} as PersonEntry)
);
spyOn(alfrescoApi.searchApi, 'search').and.returnValue(
Promise.resolve(page)
);
spyOn(alfrescoApi.searchApi, 'search').and.returnValue(Promise.resolve(page));
});
it('should call document list reload on fileUploadComplete event', fakeAsync(() => {

View File

@@ -58,18 +58,12 @@ export class RecentFilesComponent extends PageComponent implements OnInit {
super.ngOnInit();
this.subscriptions = this.subscriptions.concat([
this.uploadService.fileUploadComplete
.pipe(debounceTime(300))
.subscribe(() => this.onFileUploadedEvent()),
this.uploadService.fileUploadDeleted
.pipe(debounceTime(300))
.subscribe(() => this.onFileUploadedEvent()),
this.uploadService.fileUploadComplete.pipe(debounceTime(300)).subscribe(() => this.onFileUploadedEvent()),
this.uploadService.fileUploadDeleted.pipe(debounceTime(300)).subscribe(() => this.onFileUploadedEvent()),
this.breakpointObserver
.observe([Breakpoints.HandsetPortrait, Breakpoints.HandsetLandscape])
.subscribe(result => {
this.isSmallScreen = result.matches;
})
this.breakpointObserver.observe([Breakpoints.HandsetPortrait, Breakpoints.HandsetLandscape]).subscribe((result) => {
this.isSmallScreen = result.matches;
})
]);
this.columns = this.extensions.documentListPresets.recent || [];