mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-18 09:04:44 -04:00
Enforce import order with prettier
Signed-off-by: David Mehren <git@herrmehren.de>
This commit is contained in:
parent
879fd1be5a
commit
5ed2fae44e
130 changed files with 592 additions and 610 deletions
|
@ -3,36 +3,36 @@
|
|||
*
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
import { INestApplication } from '@nestjs/common';
|
||||
import { ConfigModule, ConfigService } from '@nestjs/config';
|
||||
import { Test } from '@nestjs/testing';
|
||||
import { TypeOrmModule } from '@nestjs/typeorm';
|
||||
import { promises as fs } from 'fs';
|
||||
import { join } from 'path';
|
||||
import request from 'supertest';
|
||||
import { HistoryService } from '../../src/history/history.service';
|
||||
import { NotesService } from '../../src/notes/notes.service';
|
||||
|
||||
import { PublicApiModule } from '../../src/api/public/public-api.module';
|
||||
import { AuthModule } from '../../src/auth/auth.module';
|
||||
import { MockAuthGuard } from '../../src/auth/mock-auth.guard';
|
||||
import { TokenAuthGuard } from '../../src/auth/token-auth.guard';
|
||||
import appConfigMock from '../../src/config/mock/app.config.mock';
|
||||
import mediaConfigMock from '../../src/config/mock/media.config.mock';
|
||||
import { GroupsModule } from '../../src/groups/groups.module';
|
||||
import { HistoryEntryUpdateDto } from '../../src/history/history-entry-update.dto';
|
||||
import { HistoryEntryDto } from '../../src/history/history-entry.dto';
|
||||
import { HistoryEntry } from '../../src/history/history-entry.entity';
|
||||
import { UsersService } from '../../src/users/users.service';
|
||||
import { TokenAuthGuard } from '../../src/auth/token-auth.guard';
|
||||
import { MockAuthGuard } from '../../src/auth/mock-auth.guard';
|
||||
import { TypeOrmModule } from '@nestjs/typeorm';
|
||||
import { PublicApiModule } from '../../src/api/public/public-api.module';
|
||||
import { NotesModule } from '../../src/notes/notes.module';
|
||||
import { PermissionsModule } from '../../src/permissions/permissions.module';
|
||||
import { GroupsModule } from '../../src/groups/groups.module';
|
||||
import { LoggerModule } from '../../src/logger/logger.module';
|
||||
import { AuthModule } from '../../src/auth/auth.module';
|
||||
import { UsersModule } from '../../src/users/users.module';
|
||||
import { HistoryModule } from '../../src/history/history.module';
|
||||
import { ConfigModule, ConfigService } from '@nestjs/config';
|
||||
import mediaConfigMock from '../../src/config/mock/media.config.mock';
|
||||
import appConfigMock from '../../src/config/mock/app.config.mock';
|
||||
import { User } from '../../src/users/user.entity';
|
||||
import { MediaService } from '../../src/media/media.service';
|
||||
import { HistoryService } from '../../src/history/history.service';
|
||||
import { LoggerModule } from '../../src/logger/logger.module';
|
||||
import { MediaModule } from '../../src/media/media.module';
|
||||
import { promises as fs } from 'fs';
|
||||
import { MediaService } from '../../src/media/media.service';
|
||||
import { NoteMetadataDto } from '../../src/notes/note-metadata.dto';
|
||||
import { join } from 'path';
|
||||
import { NotesModule } from '../../src/notes/notes.module';
|
||||
import { NotesService } from '../../src/notes/notes.service';
|
||||
import { PermissionsModule } from '../../src/permissions/permissions.module';
|
||||
import { User } from '../../src/users/user.entity';
|
||||
import { UsersModule } from '../../src/users/users.module';
|
||||
import { UsersService } from '../../src/users/users.service';
|
||||
|
||||
// TODO Tests have to be reworked using UserService functions
|
||||
|
||||
|
@ -104,7 +104,7 @@ describe('Me', () => {
|
|||
.get('/me/history')
|
||||
.expect('Content-Type', /json/)
|
||||
.expect(200);
|
||||
const history = <HistoryEntryDto[]>response.body;
|
||||
const history: HistoryEntryDto[] = response.body;
|
||||
expect(history.length).toEqual(1);
|
||||
const historyDto = historyService.toHistoryEntryDto(createdHistoryEntry);
|
||||
for (const historyEntry of history) {
|
||||
|
@ -128,7 +128,7 @@ describe('Me', () => {
|
|||
.get(`/me/history/${noteName}`)
|
||||
.expect('Content-Type', /json/)
|
||||
.expect(200);
|
||||
const historyEntry = <HistoryEntryDto>response.body;
|
||||
const historyEntry: HistoryEntryDto = response.body;
|
||||
const historyEntryDto =
|
||||
historyService.toHistoryEntryDto(createdHistoryEntry);
|
||||
expect(historyEntry.identifier).toEqual(historyEntryDto.identifier);
|
||||
|
|
|
@ -3,28 +3,28 @@
|
|||
*
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
import { ConfigModule, ConfigService } from '@nestjs/config';
|
||||
import { NestExpressApplication } from '@nestjs/platform-express';
|
||||
import { Test } from '@nestjs/testing';
|
||||
import { TypeOrmModule } from '@nestjs/typeorm';
|
||||
import { promises as fs } from 'fs';
|
||||
import { join } from 'path';
|
||||
import request from 'supertest';
|
||||
|
||||
import { PublicApiModule } from '../../src/api/public/public-api.module';
|
||||
import mediaConfigMock from '../../src/config/mock/media.config.mock';
|
||||
import { AuthModule } from '../../src/auth/auth.module';
|
||||
import { MockAuthGuard } from '../../src/auth/mock-auth.guard';
|
||||
import { TokenAuthGuard } from '../../src/auth/token-auth.guard';
|
||||
import appConfigMock from '../../src/config/mock/app.config.mock';
|
||||
import mediaConfigMock from '../../src/config/mock/media.config.mock';
|
||||
import { GroupsModule } from '../../src/groups/groups.module';
|
||||
import { ConsoleLoggerService } from '../../src/logger/console-logger.service';
|
||||
import { LoggerModule } from '../../src/logger/logger.module';
|
||||
import { MediaModule } from '../../src/media/media.module';
|
||||
import { MediaService } from '../../src/media/media.service';
|
||||
import { NotesModule } from '../../src/notes/notes.module';
|
||||
import { NotesService } from '../../src/notes/notes.service';
|
||||
import { PermissionsModule } from '../../src/permissions/permissions.module';
|
||||
import { AuthModule } from '../../src/auth/auth.module';
|
||||
import { TokenAuthGuard } from '../../src/auth/token-auth.guard';
|
||||
import { MockAuthGuard } from '../../src/auth/mock-auth.guard';
|
||||
import { join } from 'path';
|
||||
import { ConsoleLoggerService } from '../../src/logger/console-logger.service';
|
||||
import { ensureDeleted } from '../utils';
|
||||
|
||||
describe('Media', () => {
|
||||
|
|
|
@ -3,31 +3,31 @@
|
|||
*
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
import { INestApplication } from '@nestjs/common';
|
||||
import { ConfigModule, ConfigService } from '@nestjs/config';
|
||||
import { Test } from '@nestjs/testing';
|
||||
import { TypeOrmModule } from '@nestjs/typeorm';
|
||||
import { promises as fs } from 'fs';
|
||||
import { join } from 'path';
|
||||
import request from 'supertest';
|
||||
|
||||
import { PublicApiModule } from '../../src/api/public/public-api.module';
|
||||
import mediaConfigMock from '../../src/config/mock/media.config.mock';
|
||||
import { AuthModule } from '../../src/auth/auth.module';
|
||||
import { MockAuthGuard } from '../../src/auth/mock-auth.guard';
|
||||
import { TokenAuthGuard } from '../../src/auth/token-auth.guard';
|
||||
import appConfigMock from '../../src/config/mock/app.config.mock';
|
||||
import mediaConfigMock from '../../src/config/mock/media.config.mock';
|
||||
import { NotInDBError } from '../../src/errors/errors';
|
||||
import { GroupsModule } from '../../src/groups/groups.module';
|
||||
import { LoggerModule } from '../../src/logger/logger.module';
|
||||
import { MediaService } from '../../src/media/media.service';
|
||||
import { NotePermissionsUpdateDto } from '../../src/notes/note-permissions.dto';
|
||||
import { NotesModule } from '../../src/notes/notes.module';
|
||||
import { NotesService } from '../../src/notes/notes.service';
|
||||
import { PermissionsModule } from '../../src/permissions/permissions.module';
|
||||
import { AuthModule } from '../../src/auth/auth.module';
|
||||
import { TokenAuthGuard } from '../../src/auth/token-auth.guard';
|
||||
import { MockAuthGuard } from '../../src/auth/mock-auth.guard';
|
||||
import { UsersService } from '../../src/users/users.service';
|
||||
import { User } from '../../src/users/user.entity';
|
||||
import { UsersModule } from '../../src/users/users.module';
|
||||
import { promises as fs } from 'fs';
|
||||
import { MediaService } from '../../src/media/media.service';
|
||||
import { NotePermissionsUpdateDto } from '../../src/notes/note-permissions.dto';
|
||||
import { join } from 'path';
|
||||
import { UsersService } from '../../src/users/users.service';
|
||||
|
||||
describe('Notes', () => {
|
||||
let app: INestApplication;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue