Skip to content

Commit e2c5dee

Browse files
committed
fix tests
1 parent fb791ec commit e2c5dee

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

server/src/apps/apps.controller.spec.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,8 @@ describe('AppsController', () => {
128128
};
129129

130130
beforeEach(async () => {
131+
process.env.KUBERO_CONSOLE_ENABLED = 'true';
132+
131133
const module: TestingModule = await Test.createTestingModule({
132134
controllers: [AppsController],
133135
providers: [

server/src/config/config.service.ts

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -366,7 +366,13 @@ export class ConfigService {
366366
}
367367

368368
getTemplateEnabled() {
369-
return process.env.KUBERO_TEMPLATES_ENABLED
369+
if (process.env.KUBERO_TEMPLATES_ENABLED == undefined) {
370+
return false;
371+
}
372+
if (process.env.KUBERO_TEMPLATES_ENABLED == 'true') {
373+
return true;
374+
}
375+
return false;
370376
}
371377

372378
public async getTemplateConfig() {

0 commit comments

Comments
 (0)