mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-23 19:47:03 -04:00
Config: Create new config mocks for tests
Signed-off-by: Philip Molares <philip.molares@udo.edu>
This commit is contained in:
parent
64846eb641
commit
e3f1d1b0f4
4 changed files with 81 additions and 1 deletions
40
src/config/mock/auth.config.mock.ts
Normal file
40
src/config/mock/auth.config.mock.ts
Normal file
|
@ -0,0 +1,40 @@
|
|||
/*
|
||||
* SPDX-FileCopyrightText: 2021 The HedgeDoc developers (see AUTHORS file)
|
||||
*
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
import { registerAs } from '@nestjs/config';
|
||||
|
||||
export default registerAs('authConfig', () => ({
|
||||
email: {
|
||||
enableLogin: true,
|
||||
enableRegister: true,
|
||||
},
|
||||
facebook: {
|
||||
clientID: undefined,
|
||||
clientSecret: undefined,
|
||||
},
|
||||
twitter: {
|
||||
consumerKey: undefined,
|
||||
consumerSecret: undefined,
|
||||
},
|
||||
github: {
|
||||
clientID: undefined,
|
||||
clientSecret: undefined,
|
||||
},
|
||||
dropbox: {
|
||||
clientID: undefined,
|
||||
clientSecret: undefined,
|
||||
appKey: undefined,
|
||||
},
|
||||
google: {
|
||||
clientID: undefined,
|
||||
clientSecret: undefined,
|
||||
apiKey: undefined,
|
||||
},
|
||||
gitlab: [],
|
||||
ldap: [],
|
||||
saml: [],
|
||||
oauth2: [],
|
||||
}));
|
19
src/config/mock/customization.config.mock.ts
Normal file
19
src/config/mock/customization.config.mock.ts
Normal file
|
@ -0,0 +1,19 @@
|
|||
/*
|
||||
* SPDX-FileCopyrightText: 2021 The HedgeDoc developers (see AUTHORS file)
|
||||
*
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
import { registerAs } from '@nestjs/config';
|
||||
|
||||
export default registerAs('customizationConfig', () => ({
|
||||
branding: {
|
||||
customName: 'ACME Corp',
|
||||
customLogo: '',
|
||||
},
|
||||
specialUrls: {
|
||||
privacy: '/test/privacy',
|
||||
termsOfUse: '/test/termsOfUse',
|
||||
imprint: '/test/imprint',
|
||||
},
|
||||
}));
|
12
src/config/mock/external-services.config.mock.ts
Normal file
12
src/config/mock/external-services.config.mock.ts
Normal file
|
@ -0,0 +1,12 @@
|
|||
/*
|
||||
* SPDX-FileCopyrightText: 2021 The HedgeDoc developers (see AUTHORS file)
|
||||
*
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
import { registerAs } from '@nestjs/config';
|
||||
|
||||
export default registerAs('externalServicesConfig', () => ({
|
||||
plantUmlServer: 'plantuml.example.com',
|
||||
imageProxy: 'imageProxy.example.com',
|
||||
}));
|
Loading…
Add table
Add a link
Reference in a new issue