Skip to content

Commit

Permalink
Merge pull request #130 from ItaloRAmaral/119-refactor
Browse files Browse the repository at this point in the history
119 refactor
  • Loading branch information
luanavfg authored May 3, 2024
2 parents df80cd2 + def3ff7 commit e5eb093
Show file tree
Hide file tree
Showing 191 changed files with 1,641 additions and 1,261 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/tests-pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ jobs:
run: |
echo "DATABASE_URL=postgresql://${{ secrets.POSTGRES_USER }}:${{ secrets.POSTGRES_PASSWORD }}@localhost:5432/${{ secrets.POSTGRES_DB }}?schema=${{ secrets.POSTGRES_SCHEMA }}" >> $GITHUB_ENV
- name: Run core-setup script
run: pnpm run core-setup --action=migrate,generate
- name: Run setup script
run: pnpm run setup --action=migrate,generate

- name: Run E2E Tests
run: pnpm run test:e2e
Expand Down
Original file line number Diff line number Diff line change
@@ -1,48 +1,48 @@
import { Module } from '@nestjs/common';
import { ConfigModule } from '@nestjs/config';

import { AuthModule } from '../../auth/auth.module';
import { CryptographyModule } from '../../cryptography/cryptography.module';
import { envSchema } from '../../env/env';
import { EnvModule } from '../../env/env.module';
import { UpdatePsychologistController } from './use-cases/psychologist/update-psychologist/update-psychologist.controller';
import { AuthModule } from './auth/auth.module';
import { CryptographyModule } from './cryptography/cryptography.module';
import { envSchema } from './env/env';
import { EnvModule } from './env/env.module';

import { BcryptHasherService } from '../../../core/shared/cryptography/use-cases/bcrypt-hasher.service';
import { PostgreSqlPrismaOrmService } from '../../database/infra/prisma/prisma.service';
import { DatabaseRepositoriesModule } from '../../database/repositories/repositories.module';
import { BcryptHasherService } from '../core/shared/cryptography/use-cases/bcrypt-hasher.service';
import { PostgreSqlPrismaOrmService } from './database/infra/prisma/prisma.service';
import { DatabaseRepositoriesModule } from './database/repositories/repositories.module';

import { NestjsCreateAppointmentService } from './use-cases/appointment/create-appointment/nestjs-create-appointment.service';
import { DeleteAppointmentController } from './use-cases/appointment/delete-appointment/delete-appointment.controller';
import { NestjsDeleteAppointmentService } from './use-cases/appointment/delete-appointment/nestjs-delete-appointment.service';
import { NestjsCreateClinicService } from './use-cases/clinic/create-clinic/nestjs-create-clinic.service';
import { NestjsDeleteClinicService } from './use-cases/clinic/delete-clinic/nestjs-delete-clinic.service';
import { NestjsUpdateClinicService } from './use-cases/clinic/update-clinic/nestjs-update-clinic.service';
import { NestjsCreatePatientService } from './use-cases/patient/create-patient/nestjs-create-patient.service';
import { NestjsDeletePatientService } from './use-cases/patient/delete-patient/nestjs-delete-patient.service';
import { NestjsUpdatePatientService } from './use-cases/patient/update-patient/nestjs-update-patient.service';
import { NestjsAuthenticatePsychologistService } from './use-cases/psychologist/authenticate-psychologist/nestjs-authenticate-psychologist.service';
import { NestjsCreatePsychologistService } from './use-cases/psychologist/create-psychologist/nestjs-create-psychologist.service';
import { NestjsDeletePsychologistService } from './use-cases/psychologist/delete-psychologist/nestjs-delete-psychologist.service';
import { NestjsUpdatePsychologistService } from './use-cases/psychologist/update-psychologist/nestjs-update-psychologist.service';
import { NestjsCreateAppointmentService } from './routes/v1/appointment/create-appointment/nestjs-create-appointment.service';
import { DeleteAppointmentController } from './routes/v1/appointment/delete-appointment/delete-appointment.controller';
import { NestjsDeleteAppointmentService } from './routes/v1/appointment/delete-appointment/nestjs-delete-appointment.service';
import { NestjsCreateClinicService } from './routes/v1/clinic/create-clinic/nestjs-create-clinic.service';
import { NestjsDeleteClinicService } from './routes/v1/clinic/delete-clinic/nestjs-delete-clinic.service';
import { NestjsUpdateClinicService } from './routes/v1/clinic/update-clinic/nestjs-update-clinic.service';
import { NestjsCreatePatientService } from './routes/v1/patient/create-patient/nestjs-create-patient.service';
import { NestjsDeletePatientService } from './routes/v1/patient/delete-patient/nestjs-delete-patient.service';
import { NestjsUpdatePatientService } from './routes/v1/patient/update-patient/nestjs-update-patient.service';
import { NestjsAuthenticatePsychologistService } from './routes/v1/psychologist/authenticate-psychologist/nestjs-authenticate-psychologist.service';
import { NestjsCreatePsychologistService } from './routes/v1/psychologist/create-psychologist/nestjs-create-psychologist.service';
import { NestjsDeletePsychologistService } from './routes/v1/psychologist/delete-psychologist/nestjs-delete-psychologist.service';
import { NestjsUpdatePsychologistService } from './routes/v1/psychologist/update-psychologist/nestjs-update-psychologist.service';

import { CreateAppointmentController } from './use-cases/appointment/create-appointment/create-appointment.controller';
import { NestjsUpdateAppointmentService } from './use-cases/appointment/update-appointment/nestjs-update-appointment.service';
import { UpdateAppointmentController } from './use-cases/appointment/update-appointment/update-appointment.controller';
import { CreateClinicController } from './use-cases/clinic/create-clinic/create-clinic.controller';
import { DeleteClinicController } from './use-cases/clinic/delete-clinic/delete-clinic.controller';
import { UpdateClinicController } from './use-cases/clinic/update-clinic/update-clinic.controller';
import { CreatePatientAppointmentRegistryController } from './use-cases/patient-appointment-registry/create-patient-appointment-registry/create-patient-appointment-registry.controller';
import { NestjsCreatePatientAppointmentRegistryService } from './use-cases/patient-appointment-registry/create-patient-appointment-registry/nestjs-create-patient-appointment-registry.service';
import { DeletePatientAppointmentRegistryController } from './use-cases/patient-appointment-registry/delete-patient-appointment-registry/delete-patient-appointment-registry.controller';
import { NestjsDeletePatientAppointmentRegistryService } from './use-cases/patient-appointment-registry/delete-patient-appointment-registry/nestjs-delete-patient-appointment-registry.service';
import { NestjsUpdatePatientAppointmentRegistryService } from './use-cases/patient-appointment-registry/update-patient-appointment-registry/nestjs-update-patient-appointment-registry.service';
import { UpdatePatientAppointmentRegistryController } from './use-cases/patient-appointment-registry/update-patient-appointment-registry/update-patient-appointment-registry.controller';
import { CreatePatientController } from './use-cases/patient/create-patient/create-patient.controller';
import { DeletePatientController } from './use-cases/patient/delete-patient/delete-patient.controller';
import { UpdatePatientController } from './use-cases/patient/update-patient/update-patient.controller';
import { AuthenticatePsychologistController } from './use-cases/psychologist/authenticate-psychologist/authenticate-psychologist.controller';
import { CreatePsychologistController } from './use-cases/psychologist/create-psychologist/create-psychologist.controller';
import { DeletePsychologistController } from './use-cases/psychologist/delete-psychologist/delete-psychologist.controller';
import { CreateAppointmentController } from './routes/v1/appointment/create-appointment/create-appointment.controller';
import { NestjsUpdateAppointmentService } from './routes/v1/appointment/update-appointment/nestjs-update-appointment.service';
import { UpdateAppointmentController } from './routes/v1/appointment/update-appointment/update-appointment.controller';
import { CreateClinicController } from './routes/v1/clinic/create-clinic/create-clinic.controller';
import { DeleteClinicController } from './routes/v1/clinic/delete-clinic/delete-clinic.controller';
import { UpdateClinicController } from './routes/v1/clinic/update-clinic/update-clinic.controller';
import { CreatePatientAppointmentRegistryController } from './routes/v1/patient-appointment-registry/create-patient-appointment-registry/create-patient-appointment-registry.controller';
import { NestjsCreatePatientAppointmentRegistryService } from './routes/v1/patient-appointment-registry/create-patient-appointment-registry/nestjs-create-patient-appointment-registry.service';
import { DeletePatientAppointmentRegistryController } from './routes/v1/patient-appointment-registry/delete-patient-appointment-registry/delete-patient-appointment-registry.controller';
import { NestjsDeletePatientAppointmentRegistryService } from './routes/v1/patient-appointment-registry/delete-patient-appointment-registry/nestjs-delete-patient-appointment-registry.service';
import { NestjsUpdatePatientAppointmentRegistryService } from './routes/v1/patient-appointment-registry/update-patient-appointment-registry/nestjs-update-patient-appointment-registry.service';
import { UpdatePatientAppointmentRegistryController } from './routes/v1/patient-appointment-registry/update-patient-appointment-registry/update-patient-appointment-registry.controller';
import { CreatePatientController } from './routes/v1/patient/create-patient/create-patient.controller';
import { DeletePatientController } from './routes/v1/patient/delete-patient/delete-patient.controller';
import { UpdatePatientController } from './routes/v1/patient/update-patient/update-patient.controller';
import { AuthenticatePsychologistController } from './routes/v1/psychologist/authenticate-psychologist/authenticate-psychologist.controller';
import { CreatePsychologistController } from './routes/v1/psychologist/create-psychologist/create-psychologist.controller';
import { DeletePsychologistController } from './routes/v1/psychologist/delete-psychologist/delete-psychologist.controller';
import { UpdatePsychologistController } from './routes/v1/psychologist/update-psychologist/update-psychologist.controller';

@Module({
imports: [
Expand Down Expand Up @@ -91,7 +91,7 @@ import { DeletePsychologistController } from './use-cases/psychologist/delete-ps
NestjsDeletePatientAppointmentRegistryService,
NestjsUpdatePatientAppointmentRegistryService,
NestjsUpdatePatientService,
NestjsUpdateAppointmentService
NestjsUpdateAppointmentService,
],
})
export class ApiModule {}

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

Loading

0 comments on commit e5eb093

Please sign in to comment.