Skip to content

Commit

Permalink
fix(core): fix --e2eTestRunner for create-nx-workspace with react nat…
Browse files Browse the repository at this point in the history
…ive (nrwl#27543)

<!-- Please make sure you have read the submission guidelines before
posting an PR -->
<!--
https://github.com/nrwl/nx/blob/master/CONTRIBUTING.md#-submitting-a-pr
-->

<!-- Please make sure that your commit message follows our format -->
<!-- Example: `fix(nx): must begin with lowercase` -->

<!-- If this is a particularly complex change or feature addition, you
can request a dedicated Nx release for this pull request branch. Mention
someone from the Nx team or the `@nrwl/nx-pipelines-reviewers` and they
will confirm if the PR warrants its own release for testing purposes,
and generate it for you if appropriate. -->

## Current Behavior
<!-- This is the behavior we have today -->
--e2eTestRunner option is not working when create-nx-workspace with
preset react native

## Expected Behavior
<!-- This is the behavior we should expect with the changes in this PR
-->
--e2eTestRunner option should be working when create-nx-workspace with
preset react native

## Related Issue(s)
<!-- Please link the issue being fixed so it gets closed when this is
merged. -->

Fixes #
  • Loading branch information
xiongemi authored Aug 26, 2024
1 parent 45e088e commit f02e2fc
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 2 additions & 0 deletions e2e/workspace-create/src/create-nx-workspace.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -307,6 +307,7 @@ describe('create-nx-workspace', () => {
preset: 'react-native',
appName,
packageManager: 'npm',
e2eTestRunner: 'none',
});

expectNoAngularDevkit();
Expand All @@ -320,6 +321,7 @@ describe('create-nx-workspace', () => {
preset: 'expo',
appName,
packageManager: 'npm',
e2eTestRunner: 'none',
});

expectNoAngularDevkit();
Expand Down
4 changes: 3 additions & 1 deletion packages/create-nx-workspace/bin/create-nx-workspace.ts
Original file line number Diff line number Diff line change
Expand Up @@ -555,7 +555,9 @@ async function determineReactOptions(
e2eTestRunner = await determineE2eTestRunner(parsedArgs);
} else if (
preset === Preset.RemixMonorepo ||
preset === Preset.RemixStandalone
preset === Preset.RemixStandalone ||
preset === Preset.ReactNative ||
preset === Preset.Expo
) {
e2eTestRunner = await determineE2eTestRunner(parsedArgs);
}
Expand Down

0 comments on commit f02e2fc

Please sign in to comment.