Twenty config core implementation (#11595)

closes https://github.com/twentyhq/core-team-issues/issues/760

---------

Co-authored-by: Charles Bochet <charlesBochet@users.noreply.github.com>
Co-authored-by: Félix Malfait <felix.malfait@gmail.com>
Co-authored-by: Félix Malfait <felix@twenty.com>
This commit is contained in:
nitin
2025-04-26 12:51:59 +05:30
committed by GitHub
parent bb8fa02899
commit a15b87649a
41 changed files with 3672 additions and 208 deletions

View File

@ -28,7 +28,7 @@ xdescribe('Microsoft dev tests : get message list service', () => {
beforeEach(async () => {
const module: TestingModule = await Test.createTestingModule({
imports: [TwentyConfigModule.forRoot({})],
imports: [TwentyConfigModule.forRoot()],
providers: [
MicrosoftGetMessageListService,
MicrosoftClientProvider,
@ -118,7 +118,7 @@ xdescribe('Microsoft dev tests : get full message list service for folders', ()
beforeEach(async () => {
const module: TestingModule = await Test.createTestingModule({
imports: [TwentyConfigModule.forRoot({})],
imports: [TwentyConfigModule.forRoot()],
providers: [
MicrosoftGetMessageListService,
MicrosoftClientProvider,
@ -207,7 +207,7 @@ xdescribe('Microsoft dev tests : get partial message list service for folders',
beforeEach(async () => {
const module: TestingModule = await Test.createTestingModule({
imports: [TwentyConfigModule.forRoot({})],
imports: [TwentyConfigModule.forRoot()],
providers: [
MicrosoftGetMessageListService,
MicrosoftClientProvider,

View File

@ -23,7 +23,7 @@ xdescribe('Microsoft dev tests : get messages service', () => {
beforeEach(async () => {
const module: TestingModule = await Test.createTestingModule({
imports: [TwentyConfigModule.forRoot({})],
imports: [TwentyConfigModule.forRoot()],
providers: [
MicrosoftGetMessagesService,
MicrosoftHandleErrorService,

View File

@ -3,7 +3,7 @@ import { Test, TestingModule } from '@nestjs/testing';
import { ConnectedAccountProvider } from 'twenty-shared/types';
import { TwentyConfigModule } from 'src/engine/core-modules/twenty-config/twenty-config.module';
import { TwentyConfigService } from 'src/engine/core-modules/twenty-config/twenty-config.service';
import { MicrosoftOAuth2ClientManagerService } from 'src/modules/connected-account/oauth2-client-manager/drivers/microsoft/microsoft-oauth2-client-manager.service';
import {
microsoftGraphBatchWithHtmlMessagesResponse,
@ -21,7 +21,6 @@ describe('Microsoft get messages service', () => {
beforeEach(async () => {
const module: TestingModule = await Test.createTestingModule({
imports: [TwentyConfigModule.forRoot({})],
providers: [
MicrosoftGetMessagesService,
MicrosoftHandleErrorService,
@ -29,6 +28,10 @@ describe('Microsoft get messages service', () => {
MicrosoftOAuth2ClientManagerService,
MicrosoftFetchByBatchService,
ConfigService,
{
provide: TwentyConfigService,
useValue: {},
},
],
}).compile();
@ -37,6 +40,10 @@ describe('Microsoft get messages service', () => {
);
});
afterEach(() => {
jest.clearAllMocks();
});
it('Should be defined', () => {
expect(service).toBeDefined();
});