minor code cleanup

This commit is contained in:
Joe Arndt 2026-02-07 21:23:01 -06:00
parent cfbd7c1550
commit 746adcd2fd
5 changed files with 28 additions and 27 deletions

View file

@ -1,5 +1,6 @@
{ {
"singleQuote": true, "singleQuote": true,
"trailingComma": "none", "trailingComma": "none",
"printWidth": 160 "printWidth": 160,
"bracketSameLine": true
} }

View file

@ -1,22 +1,22 @@
import { Test, TestingModule } from '@nestjs/testing'; // import { Test, TestingModule } from '@nestjs/testing';
import { AppController } from './app.controller'; // import { AppController } from './app.controller';
import { AppService } from './app.service'; // import { AppService } from './app.service';
//
describe('AppController', () => { // describe('AppController', () => {
let appController: AppController; // let appController: AppController;
//
beforeEach(async () => { // beforeEach(async () => {
const app: TestingModule = await Test.createTestingModule({ // const app: TestingModule = await Test.createTestingModule({
controllers: [AppController], // controllers: [AppController],
providers: [AppService], // providers: [AppService],
}).compile(); // }).compile();
//
appController = app.get<AppController>(AppController); // appController = app.get<AppController>(AppController);
}); // });
//
describe('root', () => { // describe('root', () => {
it('should return "Hello World!"', () => { // it('should return "Hello World!"', () => {
expect(appController.getHello()).toBe('Hello World!'); // expect(appController.getHello()).toBe('Hello World!');
}); // });
}); // });
}); // });

View file

@ -3,5 +3,5 @@ import { Controller, Get } from '@nestjs/common';
@Controller() @Controller()
export class AppController { export class AppController {
@Get('health') @Get('health')
health(): void { } health(): void {}
} }

View file

@ -6,6 +6,6 @@ import { ExpensesController } from './controllers/expenses/expenses.controller';
@Module({ @Module({
imports: [], imports: [],
controllers: [AppController, ExpensesController], controllers: [AppController, ExpensesController],
providers: [ExpensesService], providers: [ExpensesService]
}) })
export class AppModule {} export class AppModule {}

View file

@ -2,9 +2,9 @@ import { NestFactory } from '@nestjs/core';
import { AppModule } from './app.module'; import { AppModule } from './app.module';
import { NestExpressApplication } from '@nestjs/platform-express'; import { NestExpressApplication } from '@nestjs/platform-express';
async function bootstrap() { async function bootstrap(): Promise<void> {
const app = await NestFactory.create<NestExpressApplication>(AppModule); const app = await NestFactory.create<NestExpressApplication>(AppModule);
app.setGlobalPrefix('common-cents'); app.setGlobalPrefix('common-cents');
await app.listen(process.env.PORT ?? 3000); await app.listen(process.env.PORT ?? 3000);
} }
bootstrap(); void bootstrap();