From bc3437f18257c6a452d5c41da1df297faf1d3429 Mon Sep 17 00:00:00 2001 From: Dominic Saadi Date: Sun, 21 Jan 2024 23:04:01 +0000 Subject: [PATCH] skip yarn install in --yes to avoid timeouts --- packages/create-redwood-app/tests/e2e.test.ts | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/packages/create-redwood-app/tests/e2e.test.ts b/packages/create-redwood-app/tests/e2e.test.ts index 3e6d31564ffb..86dd9724fa48 100644 --- a/packages/create-redwood-app/tests/e2e.test.ts +++ b/packages/create-redwood-app/tests/e2e.test.ts @@ -53,8 +53,12 @@ describe('create-redwood-app', () => { expect(p.stderr).toMatchInlineSnapshot(`"[?25l[?25h"`) }) - test.skip('--yes, -y', async () => { - const p = await $`yarn create-redwood-app ./redwood-app --yes` + test('--yes, -y', async () => { + // Running `yarn install` in Jest test times out and the subsequent step, + // generating types, is also flakey since `yarn pack` seems to skip `.yarnrc.yml` + // which is necessary for configuring a proper install. + const p = + await $`yarn create-redwood-app ./redwood-app --no-yarn-install --yes` expect(p.exitCode).toEqual(0) expect(p.stdout).toMatchInlineSnapshot(` @@ -66,10 +70,11 @@ describe('create-redwood-app', () => { [?25h✔ Creating your Redwood app in ./redwood-app based on command line argument ✔ Using TypeScript based on command line flag ✔ Will initialize a git repo based on command line flag - ✔ Will run yarn install based on command line flag + ✔ Will not run yarn install based on command line flag [?25l⠋ Creating project files [?25h[?25l✔ Project files created - [?25h[?25l⠋ Initializing a git repo + [?25hℹ Skipped yarn install step + [?25l⠋ Initializing a git repo [?25h[?25l✔ Initialized a git repo with commit message "Initial commit" [?25h Thanks for trying out Redwood!