diff --git a/packages/cli/src/cli/commands/init.test.ts b/packages/cli/src/cli/commands/init.test.ts index 69d46722..3eb99044 100644 --- a/packages/cli/src/cli/commands/init.test.ts +++ b/packages/cli/src/cli/commands/init.test.ts @@ -46,29 +46,6 @@ test("should be able to init starter kit for nextjs template", async () => { fs.rmSync(appFolder, { recursive: true, force: true }); }); -test("should be able to init starter kit for gatsby template", async () => { - const appFolder = tmp.tmpNameSync(); - - await executePCC("init", [appFolder, "--template", "gatsby", "--use-pnpm"]); - - // Eslint should not be initialized - expect(fs.existsSync(`${appFolder}/.eslintrc.json`)).toBe(false); - - // Checking if primary required files for Gatsby starter kit are created. - expect(fs.existsSync(`${appFolder}/gatsby-browser.js`)).toBe(true); - expect(fs.existsSync(`${appFolder}/gatsby-config.js`)).toBe(true); - expect(fs.existsSync(`${appFolder}/gatsby-browser.js`)).toBe(true); - - // package.json checks - expect(fs.existsSync(`${appFolder}/package.json`)).toBe(true); - const packageJson = JSON.parse( - readFileSync(`${appFolder}/package.json`).toString(), - ); - expect(packageJson.name).toBe(path.parse(appFolder).base); - - // Remove app folder - fs.rmSync(appFolder, { recursive: true, force: true }); -}); test("should be able to init starter kit for nextjs template with typescript", async () => { const appFolder = tmp.tmpNameSync(); @@ -99,33 +76,6 @@ test("should be able to init starter kit for nextjs template with typescript", a fs.rmSync(appFolder, { recursive: true, force: true }); }); -test("should be able to init starter kit for gatsby template with typescript", async () => { - const appFolder = tmp.tmpNameSync(); - - await executePCC("init", [appFolder, "--template", "gatsby", "--ts"]); - - // Check that TypesScript source files exist. - expect(fs.existsSync(`${appFolder}/src/templates/index.tsx`)).toBe(true); - - // Eslint should not be initialized - expect(fs.existsSync(`${appFolder}/.eslintrc.json`)).toBe(false); - - // Checking if primary required files for Gatsby starter kit are created - expect(fs.existsSync(`${appFolder}/gatsby-browser.js`)).toBe(true); - expect(fs.existsSync(`${appFolder}/gatsby-config.js`)).toBe(true); - expect(fs.existsSync(`${appFolder}/gatsby-browser.js`)).toBe(true); - - // package.json checks - expect(fs.existsSync(`${appFolder}/package.json`)).toBe(true); - const packageJson = JSON.parse( - readFileSync(`${appFolder}/package.json`).toString(), - ); - expect(packageJson.name).toBe(path.parse(appFolder).base); - - // Remove app folder - fs.rmSync(appFolder, { recursive: true, force: true }); -}); - test("should be able to init starter kit with eslint and app name", async () => { const appFolder = tmp.tmpNameSync(); diff --git a/packages/cli/src/cli/commands/init.ts b/packages/cli/src/cli/commands/init.ts index f499b7ad..220e93ac 100644 --- a/packages/cli/src/cli/commands/init.ts +++ b/packages/cli/src/cli/commands/init.ts @@ -274,10 +274,6 @@ export const INIT_EXAMPLES = [ description: "Create project with nextjs template", command: "pcc init new_proj", }, - { - description: "Create project with gatsby template", - command: "pcc init new_proj --template=gatsby", - }, { description: "Create project using pnpm package manager", command: "pcc init new_proj --use-pnpm",