From db46661e12cba35c02e803f27834b04bbdf8177d Mon Sep 17 00:00:00 2001 From: Miroslav Jonas Date: Fri, 31 Mar 2023 12:23:50 +0200 Subject: [PATCH] fix(core): replace empty preset with apps --- e2e/utils/create-project-utils.ts | 2 +- .../src/create-nx-workspace.test.ts | 18 +++++++++--------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/e2e/utils/create-project-utils.ts b/e2e/utils/create-project-utils.ts index add78ac4917a20..455bd428fb3d75 100644 --- a/e2e/utils/create-project-utils.ts +++ b/e2e/utils/create-project-utils.ts @@ -47,7 +47,7 @@ export function newProject({ if (!directoryExists(tmpBackupProjPath())) { runCreateWorkspace(projScope, { - preset: 'empty', + preset: 'apps', packageManager, }); diff --git a/e2e/workspace-create/src/create-nx-workspace.test.ts b/e2e/workspace-create/src/create-nx-workspace.test.ts index 682792de87e8b2..96681b7b09e15b 100644 --- a/e2e/workspace-create/src/create-nx-workspace.test.ts +++ b/e2e/workspace-create/src/create-nx-workspace.test.ts @@ -96,7 +96,7 @@ describe('create-nx-workspace', () => { it('should be able to create an empty workspace built for apps', () => { const wsName = uniq('apps'); runCreateWorkspace(wsName, { - preset: 'empty', + preset: 'apps', packageManager, }); @@ -273,7 +273,7 @@ describe('create-nx-workspace', () => { it('should be able to create a workspace with a custom base branch and HEAD', () => { const wsName = uniq('branch'); runCreateWorkspace(wsName, { - preset: 'empty', + preset: 'apps', base: 'main', packageManager, }); @@ -282,7 +282,7 @@ describe('create-nx-workspace', () => { it('should be able to create a workspace with custom commit information', () => { const wsName = uniq('branch'); runCreateWorkspace(wsName, { - preset: 'empty', + preset: 'apps', extraArgs: '--commit.name="John Doe" --commit.email="myemail@test.com" --commit.message="Custom commit message!"', packageManager, @@ -307,8 +307,8 @@ describe('create-nx-workspace', () => { process.env.SELECTED_PM = 'npm'; runCreateWorkspace(wsName, { - preset: 'empty', - packageManager, + preset: 'apps', + packageManager: 'npm', }); checkFilesDoNotExist('yarn.lock'); @@ -320,7 +320,7 @@ describe('create-nx-workspace', () => { it('should return error when ci workflow is selected but no cloud is set up', () => { const wsName = uniq('github'); runCreateWorkspace(wsName, { - preset: 'empty', + preset: 'apps', packageManager, ci: 'circleci', }); @@ -332,7 +332,7 @@ describe('create-nx-workspace', () => { function setupProject(envPm: 'npm' | 'yarn' | 'pnpm') { process.env.SELECTED_PM = envPm; runCreateWorkspace(uniq('pm'), { - preset: 'empty', + preset: 'apps', packageManager: envPm, useDetectedPm: true, }); @@ -379,7 +379,7 @@ describe('create-nx-workspace', () => { describe('create-nx-workspace custom parent folder', () => { const tmpDir = `${e2eCwd}/${uniq('with space')}`; - const wsName = uniq('empty'); + const wsName = uniq('parent'); const packageManager = getSelectedPackageManager() || 'pnpm'; afterEach(() => cleanupProject({ cwd: `${tmpDir}/${wsName}` })); @@ -388,7 +388,7 @@ describe('create-nx-workspace custom parent folder', () => { mkdirSync(tmpDir, { recursive: true }); runCreateWorkspace(wsName, { - preset: 'empty', + preset: 'apps', packageManager, cwd: tmpDir, });