diff --git a/.changeset/forty-students-attend.md b/.changeset/forty-students-attend.md new file mode 100644 index 0000000000..a845151cc8 --- /dev/null +++ b/.changeset/forty-students-attend.md @@ -0,0 +1,2 @@ +--- +--- diff --git a/.eslint_dictionary.json b/.eslint_dictionary.json index cbc5ef2ebb..7ce59076a6 100644 --- a/.eslint_dictionary.json +++ b/.eslint_dictionary.json @@ -43,6 +43,7 @@ "globals", "grantable", "graphql", + "homedir", "hotswap", "iamv2", "identitypool", @@ -124,6 +125,7 @@ "versioned", "versioning", "whoami", + "workspace", "yaml", "yargs" ] diff --git a/packages/integration-tests/src/test-live-dependency-health-checks/health_checks.test.ts b/packages/integration-tests/src/test-live-dependency-health-checks/health_checks.test.ts index b734b398b7..52bcfa30fa 100644 --- a/packages/integration-tests/src/test-live-dependency-health-checks/health_checks.test.ts +++ b/packages/integration-tests/src/test-live-dependency-health-checks/health_checks.test.ts @@ -29,13 +29,22 @@ const cfnClient = new CloudFormationClient(); */ void describe('Live dependency health checks', { concurrency: true }, () => { before(async () => { - // nuke the npx cache to ensure we are installing latest versions of packages from the npm + // Nuke the npx cache to ensure we are installing latest versions of packages from the npm. const { stdout } = await execa('npm', ['config', 'get', 'cache']); const npxCacheLocation = path.join(stdout.toString().trim(), '_npx'); if (existsSync(npxCacheLocation)) { await fs.rm(npxCacheLocation, { recursive: true }); } + + // Force 'create-amplify' installation in npx cache by executing help command + // before tests run. Otherwise, installing 'create-amplify' concurrently + // may lead to race conditions and corrupted npx cache. + await execa('npm', ['create', 'amplify', '--yes', '--', '--help'], { + // Command must run outside of 'amplify-backend' workspace. + cwd: os.homedir(), + stdio: 'inherit', + }); }); void describe('pipeline deployment', () => {