feat(core): Read ephemeral license from environment and clean up ee flags (#5797)

* remove enterprise feature schema for license.cert

* bump license sdk version

* Update packages/cli/package.json

Co-authored-by: Cornelius Suermann <cornelius@n8n.io>

---------

Co-authored-by: Cornelius Suermann <cornelius@n8n.io>
This commit is contained in:
Michael Auerswald
2023-03-28 17:21:40 +02:00
committed by GitHub
parent 5f6183a031
commit a81ca7c19c
18 changed files with 59 additions and 69 deletions

View File

@@ -7,22 +7,25 @@ import { randomEmail, randomName, randomValidPassword } from '../shared/random';
import * as testDb from '../shared/testDb';
import * as utils from '../shared/utils';
import { sampleConfig } from './sampleMetadata';
import Container from 'typedi';
import { License } from '../../../src/License';
let owner: User;
let authOwnerAgent: SuperAgentTest;
async function enableSaml(enable: boolean) {
await setSamlLoginEnabled(enable);
config.set('enterprise.features.saml', enable);
}
beforeAll(async () => {
Container.get(License).isSamlEnabled = () => true;
const app = await utils.initTestServer({ endpointGroups: ['me', 'saml'] });
owner = await testDb.createOwner();
authOwnerAgent = utils.createAuthAgent(app)(owner);
});
afterAll(async () => {
Container.reset();
await testDb.terminate();
});