Deprecated files deleted
This commit is contained in:
parent
4bd2bd4f12
commit
6ade26da51
5 changed files with 0 additions and 75 deletions
|
|
@ -1,22 +0,0 @@
|
|||
import { Test, TestingModule } from '@nestjs/testing';
|
||||
import { AppController } from './app.controller';
|
||||
import { AppService } from './app.service';
|
||||
|
||||
describe('AppController', () => {
|
||||
let appController: AppController;
|
||||
|
||||
beforeEach(async () => {
|
||||
const app: TestingModule = await Test.createTestingModule({
|
||||
controllers: [AppController],
|
||||
providers: [AppService],
|
||||
}).compile();
|
||||
|
||||
appController = app.get<AppController>(AppController);
|
||||
});
|
||||
|
||||
describe('root', () => {
|
||||
it('should return "Hello World!"', () => {
|
||||
expect(appController.getHello()).toBe('Hello World!');
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
@ -1,16 +0,0 @@
|
|||
import { Body, Controller, Post } from "@nestjs/common";
|
||||
import { AppService } from './app.service';
|
||||
import { RedmineEventsGateway } from "./events/redmine-events.gateway";
|
||||
|
||||
@Controller()
|
||||
export class AppController {
|
||||
constructor(
|
||||
private readonly appService: AppService,
|
||||
private readonly redmineEventsGateway: RedmineEventsGateway
|
||||
) {}
|
||||
|
||||
@Post("append-issues")
|
||||
async appendIssues(@Body() issues: number[]): Promise<void> {
|
||||
this.redmineEventsGateway.addIssues(issues)
|
||||
}
|
||||
}
|
||||
|
|
@ -1,19 +0,0 @@
|
|||
import { Module } from '@nestjs/common';
|
||||
import { AppController } from './app.controller';
|
||||
import { AppService } from './app.service';
|
||||
import { RedmineEventsGateway } from './events/redmine-events.gateway';
|
||||
import { ServeStaticModule } from '@nestjs/serve-static';
|
||||
import { join } from 'path';
|
||||
import MainConfig from './configs/main-config';
|
||||
import { ConfigModule } from '@nestjs/config';
|
||||
import { RedmineDataLoader } from './redmine-data-loader/redmine-data-loader';
|
||||
|
||||
@Module({
|
||||
imports: [
|
||||
ServeStaticModule.forRoot({rootPath: join(__dirname, '..', 'client')}),
|
||||
ConfigModule.forRoot({load: [MainConfig]})
|
||||
],
|
||||
controllers: [AppController],
|
||||
providers: [AppService, RedmineEventsGateway, RedmineDataLoader],
|
||||
})
|
||||
export class AppModule {}
|
||||
|
|
@ -1,8 +0,0 @@
|
|||
import { Injectable } from '@nestjs/common';
|
||||
|
||||
@Injectable()
|
||||
export class AppService {
|
||||
getHello(): string {
|
||||
return 'Hello World!';
|
||||
}
|
||||
}
|
||||
|
|
@ -1,10 +0,0 @@
|
|||
import { NestFactory } from '@nestjs/core';
|
||||
import { AppModule } from './app.module';
|
||||
|
||||
process.env['NODE_TLS_REJECT_UNAUTHORIZED'] = "0";
|
||||
|
||||
async function bootstrap() {
|
||||
const app = await NestFactory.create(AppModule);
|
||||
await app.listen(process.env['PORT'] || 3000);
|
||||
}
|
||||
bootstrap();
|
||||
Loading…
Reference in a new issue