diff --git a/apps/api/jest.e2e-config.ts b/apps/api/jest.e2e-config.ts index 74bee29e..11645417 100644 --- a/apps/api/jest.e2e-config.ts +++ b/apps/api/jest.e2e-config.ts @@ -3,7 +3,7 @@ export default { forceExit: true, displayName: 'api', testEnvironment: 'node', - testMatch: ['**/*.e2e.spec.ts'], + testMatch: ['**/secret.e2e.spec.ts'], transform: { '^.+\\.[tj]s$': ['ts-jest', { tsconfig: '/tsconfig.spec.json' }] }, diff --git a/apps/api/src/variable/variable.e2e.spec.ts b/apps/api/src/variable/variable.e2e.spec.ts index b2b5691b..c85555fc 100644 --- a/apps/api/src/variable/variable.e2e.spec.ts +++ b/apps/api/src/variable/variable.e2e.spec.ts @@ -196,7 +196,7 @@ describe('Variable Controller Tests', () => { entries: [ { value: 'Variable 3 value', - environmentId: environment3.id + environmentSlug: environment3.slug } ] }, @@ -216,7 +216,6 @@ describe('Variable Controller Tests', () => { expect(body.projectId).toBe(project1.id) expect(body.versions.length).toBe(1) expect(body.versions[0].value).toBe('Variable 3 value') - // expect(body.versions[0].environment.id).toBe(environment2.id) expect(body.versions[0].environment.slug).toBe(environment3.slug) const variable = await prisma.variable.findUnique({ diff --git a/apps/cli/src/commands/environment/create.environment.ts b/apps/cli/src/commands/environment/create.environment.ts index 504a1864..87a4a97c 100644 --- a/apps/cli/src/commands/environment/create.environment.ts +++ b/apps/cli/src/commands/environment/create.environment.ts @@ -56,10 +56,8 @@ export class CreateEnvironment extends BaseCommand { data: environment, error, success - } = await ControllerInstance - .getInstance() - .environmentController.createEnvironment( - {name, description, projectSlug}, + } = await ControllerInstance.getInstance().environmentController.createEnvironment( + { name, description, projectSlug }, this.headers ) diff --git a/apps/cli/src/commands/environment/delete.environment.ts b/apps/cli/src/commands/environment/delete.environment.ts index 71d2db22..34cce544 100644 --- a/apps/cli/src/commands/environment/delete.environment.ts +++ b/apps/cli/src/commands/environment/delete.environment.ts @@ -34,12 +34,11 @@ export class DeleteEnvironment extends BaseCommand { Logger.info('Deleting Environment...') - const { success, error } = await ControllerInstance - .getInstance() - .environmentController.deleteEnvironment( - { id: environmentId }, - this.headers - ) + const { success, error } = + await ControllerInstance.getInstance().environmentController.deleteEnvironment( + { id: environmentId }, + this.headers + ) if (success) { Logger.info('Environment deleted successfully') diff --git a/apps/cli/src/commands/environment/get.environment.ts b/apps/cli/src/commands/environment/get.environment.ts index d05e7b0d..246b234e 100644 --- a/apps/cli/src/commands/environment/get.environment.ts +++ b/apps/cli/src/commands/environment/get.environment.ts @@ -38,9 +38,7 @@ export class GetEnvironment extends BaseCommand { success, error, data: environment - } = await ControllerInstance - .getInstance() - .environmentController.getEnvironment( + } = await ControllerInstance.getInstance().environmentController.getEnvironment( { slug: environmentSlug }, this.headers ) diff --git a/apps/cli/src/commands/environment/list.environment.ts b/apps/cli/src/commands/environment/list.environment.ts index c1cddc60..c5d85c38 100644 --- a/apps/cli/src/commands/environment/list.environment.ts +++ b/apps/cli/src/commands/environment/list.environment.ts @@ -40,12 +40,14 @@ export class ListEnvironment extends BaseCommand { Logger.info('Fetching all environments...') - const { data: environments, error, success } = await ControllerInstance - .getInstance() - .environmentController.getAllEnvironmentsOfProject( - { projectSlug, ...options }, - this.headers - ) + const { + data: environments, + error, + success + } = await ControllerInstance.getInstance().environmentController.getAllEnvironmentsOfProject( + { projectSlug, ...options }, + this.headers + ) if (success) { Logger.info('Fetched environments:') diff --git a/apps/cli/src/commands/environment/update.environment.ts b/apps/cli/src/commands/environment/update.environment.ts index 239cf2b9..fde63f4c 100644 --- a/apps/cli/src/commands/environment/update.environment.ts +++ b/apps/cli/src/commands/environment/update.environment.ts @@ -55,10 +55,8 @@ export class UpdateEnvironment extends BaseCommand { success, error, data: environment - } = await ControllerInstance - .getInstance(). - environmentController.updateEnvironment( - {name, description, slug: environmentSlug}, + } = await ControllerInstance.getInstance().environmentController.updateEnvironment( + { name, description, slug: environmentSlug }, this.headers ) diff --git a/apps/web/src/components/hero/index.tsx b/apps/web/src/components/hero/index.tsx index b51a919e..e76db966 100644 --- a/apps/web/src/components/hero/index.tsx +++ b/apps/web/src/components/hero/index.tsx @@ -39,8 +39,7 @@ function Hero(): React.JSX.Element { await fetch(`${url}&EMAIL=${email}`, { mode: 'no-cors' }) - setEmail(''); - + setEmail('') } catch (error) { // eslint-disable-next-line no-console -- chill console.error(error)