diff --git a/tests/integration/cli/help/__snapshots__/cli-help.test.js.snap b/tests/integration/cli/help/__snapshots__/cli-help.test.js.snap index ecabc79d7..dd8124c64 100644 --- a/tests/integration/cli/help/__snapshots__/cli-help.test.js.snap +++ b/tests/integration/cli/help/__snapshots__/cli-help.test.js.snap @@ -23,7 +23,7 @@ Options: --generate-example Generate an example project and add the library module to it with symlink by defult, with overwrite of example metro.config.js to add workaround for Metro symlink issue - requires both react-native-cli and yarn to be installed globally --example-file-linkage DEPRECATED: do \`yarn add file:../\` instead of \`yarn add link:../\` in a generated example project, and add a postinstall workaround script, with no overwrite of example metro.config.js --example-name [exampleName] Name for the example project (default: \\"example\\") - --example-react-native-version [exampleReactNativeVersion] React Native version for the generated example project (default: \\"react-native@latest\\") + --example-react-native-version [exampleReactNativeVersion] React Native template version for the generated example project, for example: react-native-tvos, react-native-tvos@0.62.2-1 (requires --tvos-enabled option); react-native@0.62 (default: \\"react-native@latest\\") --write-example-podfile [iOS] EXPERIMENTAL FEATURE NOT SUPPORTED: write (or overwrite) example ios/Podfile -h, --help display help for command" `; diff --git a/tests/integration/cli/noargs/__snapshots__/cli-noargs.test.js.snap b/tests/integration/cli/noargs/__snapshots__/cli-noargs.test.js.snap index a850969b6..d7dfcc213 100644 --- a/tests/integration/cli/noargs/__snapshots__/cli-noargs.test.js.snap +++ b/tests/integration/cli/noargs/__snapshots__/cli-noargs.test.js.snap @@ -23,7 +23,7 @@ Options: --generate-example Generate an example project and add the library module to it with symlink by defult, with overwrite of example metro.config.js to add workaround for Metro symlink issue - requires both react-native-cli and yarn to be installed globally --example-file-linkage DEPRECATED: do \`yarn add file:../\` instead of \`yarn add link:../\` in a generated example project, and add a postinstall workaround script, with no overwrite of example metro.config.js --example-name [exampleName] Name for the example project (default: \\"example\\") - --example-react-native-version [exampleReactNativeVersion] React Native version for the generated example project (default: \\"react-native@latest\\") + --example-react-native-version [exampleReactNativeVersion] React Native template version for the generated example project, for example: react-native-tvos, react-native-tvos@0.62.2-1 (requires --tvos-enabled option); react-native@0.62 (default: \\"react-native@latest\\") --write-example-podfile [iOS] EXPERIMENTAL FEATURE NOT SUPPORTED: write (or overwrite) example ios/Podfile -h, --help display help for command" `; diff --git a/tests/with-injection/cli/command/object/__snapshots__/lib-cli-command-object-text.test.js.snap b/tests/with-injection/cli/command/object/__snapshots__/lib-cli-command-object-text.test.js.snap index fb8eedde5..6efd21c8b 100644 --- a/tests/with-injection/cli/command/object/__snapshots__/lib-cli-command-object-text.test.js.snap +++ b/tests/with-injection/cli/command/object/__snapshots__/lib-cli-command-object-text.test.js.snap @@ -82,7 +82,7 @@ Object { Object { "command": "--example-react-native-version [exampleReactNativeVersion]", "default": "react-native@latest", - "description": "React Native version for the generated example project", + "description": "React Native template version for the generated example project, for example: react-native-tvos, react-native-tvos@0.62.2-1 (requires --tvos-enabled option); react-native@0.62", }, Object { "command": "--write-example-podfile", diff --git a/tests/with-injection/create/view/with-example/with-defaults/__snapshots__/create-view-with-example-with-defaults.test.js.snap b/tests/with-injection/create/view/with-example/with-defaults/__snapshots__/create-view-with-example-with-defaults.test.js.snap index 1ba121866..2102bda9f 100644 --- a/tests/with-injection/create/view/with-example/with-defaults/__snapshots__/create-view-with-example-with-defaults.test.js.snap +++ b/tests/with-injection/create/view/with-example/with-defaults/__snapshots__/create-view-with-example-with-defaults.test.js.snap @@ -2,8 +2,6 @@ exports[`create alice-bobbi view module with example, with defaults 1`] = ` Array [ - "* execa.commandSync command: react-native --version options: {\\"stdio\\":\\"inherit\\"} -", "* execa.commandSync command: yarn --version options: {\\"stdio\\":\\"inherit\\"} ", "* ensureDir dir: react-native-alice-bobbi @@ -792,13 +790,21 @@ content: <<<<<<<< ======== >>>>>>>> ", - "* execa.commandSync command: react-native init example --version react-native@latest options: {\\"cwd\\":\\"./react-native-alice-bobbi\\",\\"stdio\\":\\"inherit\\"} -", - "* ensureDir dir: react-native-alice-bobbi/example/ + Object { + "call": "reactNativeInit", + "nameArray": Array [ + "example", + ], + "options": Object { + "directory": "react-native-alice-bobbi/example", + "template": "react-native@latest", + }, + }, + "* ensureDir dir: .../react-native-alice-bobbi/example/ ", - "* ensureDir dir: react-native-alice-bobbi/example/ + "* ensureDir dir: .../react-native-alice-bobbi/example/ ", - "* outputFile name: react-native-alice-bobbi/example/metro.config.js + "* outputFile name: .../react-native-alice-bobbi/example/metro.config.js content: -------- // metro.config.js @@ -832,7 +838,7 @@ module.exports = { <<<<<<<< ======== >>>>>>>> ", - "* outputFile name: react-native-alice-bobbi/example/App.js + "* outputFile name: .../react-native-alice-bobbi/example/App.js content: -------- /** @@ -883,11 +889,11 @@ const styles = StyleSheet.create({ <<<<<<<< ======== >>>>>>>> ", - "* execa.commandSync command: yarn add link:../ options: {\\"cwd\\":\\"./react-native-alice-bobbi/example\\",\\"stdio\\":\\"inherit\\"} + "* execa.commandSync command: yarn add link:../ options: {\\"cwd\\":\\".../react-native-alice-bobbi/example\\",\\"stdio\\":\\"inherit\\"} ", - "* execa.commandSync command: pod --version options: {\\"cwd\\":\\"./react-native-alice-bobbi/example/ios\\",\\"stdio\\":\\"inherit\\"} + "* execa.commandSync command: pod --version options: {\\"cwd\\":\\".../react-native-alice-bobbi/example/ios\\",\\"stdio\\":\\"inherit\\"} ", - "* execa.commandSync command: pod install options: {\\"cwd\\":\\"./react-native-alice-bobbi/example/ios\\",\\"stdio\\":\\"inherit\\"} + "* execa.commandSync command: pod install options: {\\"cwd\\":\\".../react-native-alice-bobbi/example/ios\\",\\"stdio\\":\\"inherit\\"} ", ] `; diff --git a/tests/with-injection/create/view/with-example/with-options/__snapshots__/create-view-with-example-with-options.test.js.snap b/tests/with-injection/create/view/with-example/with-options/__snapshots__/create-view-with-example-with-options.test.js.snap index dd047d555..7bfcecd36 100644 --- a/tests/with-injection/create/view/with-example/with-options/__snapshots__/create-view-with-example-with-options.test.js.snap +++ b/tests/with-injection/create/view/with-example/with-options/__snapshots__/create-view-with-example-with-options.test.js.snap @@ -2,8 +2,6 @@ exports[`create alice-bobbi view module with example, with custom config options 1`] = ` Array [ - "* execa.commandSync command: react-native --version options: {\\"stdio\\":\\"inherit\\"} -", "* execa.commandSync command: yarn --version options: {\\"stdio\\":\\"inherit\\"} ", "* ensureDir dir: react-native-alice-bobbi @@ -792,13 +790,21 @@ content: <<<<<<<< ======== >>>>>>>> ", - "* execa.commandSync command: react-native init test-demo --version react-native@0.60 options: {\\"cwd\\":\\"./react-native-alice-bobbi\\",\\"stdio\\":\\"inherit\\"} -", - "* ensureDir dir: react-native-alice-bobbi/test-demo/ + Object { + "call": "reactNativeInit", + "nameArray": Array [ + "test-demo", + ], + "options": Object { + "directory": "react-native-alice-bobbi/test-demo", + "template": "react-native@0.60", + }, + }, + "* ensureDir dir: .../react-native-alice-bobbi/test-demo/ ", - "* ensureDir dir: react-native-alice-bobbi/test-demo/ + "* ensureDir dir: .../react-native-alice-bobbi/test-demo/ ", - "* outputFile name: react-native-alice-bobbi/test-demo/metro.config.js + "* outputFile name: .../react-native-alice-bobbi/test-demo/metro.config.js content: -------- // metro.config.js @@ -832,7 +838,7 @@ module.exports = { <<<<<<<< ======== >>>>>>>> ", - "* outputFile name: react-native-alice-bobbi/test-demo/App.js + "* outputFile name: .../react-native-alice-bobbi/test-demo/App.js content: -------- /** @@ -883,11 +889,11 @@ const styles = StyleSheet.create({ <<<<<<<< ======== >>>>>>>> ", - "* execa.commandSync command: yarn add link:../ options: {\\"cwd\\":\\"./react-native-alice-bobbi/test-demo\\",\\"stdio\\":\\"inherit\\"} + "* execa.commandSync command: yarn add link:../ options: {\\"cwd\\":\\".../react-native-alice-bobbi/test-demo\\",\\"stdio\\":\\"inherit\\"} ", - "* execa.commandSync command: pod --version options: {\\"cwd\\":\\"./react-native-alice-bobbi/test-demo/ios\\",\\"stdio\\":\\"inherit\\"} + "* execa.commandSync command: pod --version options: {\\"cwd\\":\\".../react-native-alice-bobbi/test-demo/ios\\",\\"stdio\\":\\"inherit\\"} ", - "* execa.commandSync command: pod install options: {\\"cwd\\":\\"./react-native-alice-bobbi/test-demo/ios\\",\\"stdio\\":\\"inherit\\"} + "* execa.commandSync command: pod install options: {\\"cwd\\":\\".../react-native-alice-bobbi/test-demo/ios\\",\\"stdio\\":\\"inherit\\"} ", ] `; diff --git a/tests/with-injection/create/with-example/for-android-only/__snapshots__/create-with-example-for-android-only.test.js.snap b/tests/with-injection/create/with-example/for-android-only/__snapshots__/create-with-example-for-android-only.test.js.snap index 1b32bcfb0..d985908c1 100644 --- a/tests/with-injection/create/with-example/for-android-only/__snapshots__/create-with-example-for-android-only.test.js.snap +++ b/tests/with-injection/create/with-example/for-android-only/__snapshots__/create-with-example-for-android-only.test.js.snap @@ -2,8 +2,6 @@ exports[`create alice-bobbi module with example for Android only 1`] = ` Array [ - "* execa.commandSync command: react-native --version options: {\\"stdio\\":\\"inherit\\"} -", "* execa.commandSync command: yarn --version options: {\\"stdio\\":\\"inherit\\"} ", "* ensureDir dir: react-native-alice-bobbi @@ -385,13 +383,21 @@ sdk.dir=/Users/{username}/Library/Android/sdk <<<<<<<< ======== >>>>>>>> ", - "* execa.commandSync command: react-native init example --version react-native@latest options: {\\"cwd\\":\\"./react-native-alice-bobbi\\",\\"stdio\\":\\"inherit\\"} -", - "* ensureDir dir: react-native-alice-bobbi/example/ + Object { + "call": "reactNativeInit", + "nameArray": Array [ + "example", + ], + "options": Object { + "directory": "react-native-alice-bobbi/example", + "template": "react-native@latest", + }, + }, + "* ensureDir dir: .../react-native-alice-bobbi/example/ ", - "* ensureDir dir: react-native-alice-bobbi/example/ + "* ensureDir dir: .../react-native-alice-bobbi/example/ ", - "* outputFile name: react-native-alice-bobbi/example/metro.config.js + "* outputFile name: .../react-native-alice-bobbi/example/metro.config.js content: -------- // metro.config.js @@ -425,7 +431,7 @@ module.exports = { <<<<<<<< ======== >>>>>>>> ", - "* outputFile name: react-native-alice-bobbi/example/App.js + "* outputFile name: .../react-native-alice-bobbi/example/App.js content: -------- /** @@ -488,7 +494,7 @@ const styles = StyleSheet.create({ <<<<<<<< ======== >>>>>>>> ", - "* execa.commandSync command: yarn add link:../ options: {\\"cwd\\":\\"./react-native-alice-bobbi/example\\",\\"stdio\\":\\"inherit\\"} + "* execa.commandSync command: yarn add link:../ options: {\\"cwd\\":\\".../react-native-alice-bobbi/example\\",\\"stdio\\":\\"inherit\\"} ", ] `; diff --git a/tests/with-injection/create/with-example/with-defaults/__snapshots__/create-with-example-with-defaults.test.js.snap b/tests/with-injection/create/with-example/with-defaults/__snapshots__/create-with-example-with-defaults.test.js.snap index ff9a8b7f6..8327028cf 100644 --- a/tests/with-injection/create/with-example/with-defaults/__snapshots__/create-with-example-with-defaults.test.js.snap +++ b/tests/with-injection/create/with-example/with-defaults/__snapshots__/create-with-example-with-defaults.test.js.snap @@ -2,8 +2,6 @@ exports[`create alice-bobbi module with defaults 1`] = ` Array [ - "* execa.commandSync command: react-native --version options: {\\"stdio\\":\\"inherit\\"} -", "* execa.commandSync command: yarn --version options: {\\"stdio\\":\\"inherit\\"} ", "* ensureDir dir: react-native-alice-bobbi @@ -788,13 +786,21 @@ content: <<<<<<<< ======== >>>>>>>> ", - "* execa.commandSync command: react-native init example --version react-native@latest options: {\\"cwd\\":\\"./react-native-alice-bobbi\\",\\"stdio\\":\\"inherit\\"} -", - "* ensureDir dir: react-native-alice-bobbi/example/ + Object { + "call": "reactNativeInit", + "nameArray": Array [ + "example", + ], + "options": Object { + "directory": "react-native-alice-bobbi/example", + "template": "react-native@latest", + }, + }, + "* ensureDir dir: .../react-native-alice-bobbi/example/ ", - "* ensureDir dir: react-native-alice-bobbi/example/ + "* ensureDir dir: .../react-native-alice-bobbi/example/ ", - "* outputFile name: react-native-alice-bobbi/example/metro.config.js + "* outputFile name: .../react-native-alice-bobbi/example/metro.config.js content: -------- // metro.config.js @@ -828,7 +834,7 @@ module.exports = { <<<<<<<< ======== >>>>>>>> ", - "* outputFile name: react-native-alice-bobbi/example/App.js + "* outputFile name: .../react-native-alice-bobbi/example/App.js content: -------- /** @@ -891,11 +897,11 @@ const styles = StyleSheet.create({ <<<<<<<< ======== >>>>>>>> ", - "* execa.commandSync command: yarn add link:../ options: {\\"cwd\\":\\"./react-native-alice-bobbi/example\\",\\"stdio\\":\\"inherit\\"} + "* execa.commandSync command: yarn add link:../ options: {\\"cwd\\":\\".../react-native-alice-bobbi/example\\",\\"stdio\\":\\"inherit\\"} ", - "* execa.commandSync command: pod --version options: {\\"cwd\\":\\"./react-native-alice-bobbi/example/ios\\",\\"stdio\\":\\"inherit\\"} + "* execa.commandSync command: pod --version options: {\\"cwd\\":\\".../react-native-alice-bobbi/example/ios\\",\\"stdio\\":\\"inherit\\"} ", - "* execa.commandSync command: pod install options: {\\"cwd\\":\\"./react-native-alice-bobbi/example/ios\\",\\"stdio\\":\\"inherit\\"} + "* execa.commandSync command: pod install options: {\\"cwd\\":\\".../react-native-alice-bobbi/example/ios\\",\\"stdio\\":\\"inherit\\"} ", ] `; diff --git a/tests/with-injection/create/with-example/with-missing-package-scripts/__snapshots__/recover-from-missing-package-scripts.test.js.snap b/tests/with-injection/create/with-example/with-missing-package-scripts/__snapshots__/recover-from-missing-package-scripts.test.js.snap index 5d59534f8..69a733e70 100644 --- a/tests/with-injection/create/with-example/with-missing-package-scripts/__snapshots__/recover-from-missing-package-scripts.test.js.snap +++ b/tests/with-injection/create/with-example/with-missing-package-scripts/__snapshots__/recover-from-missing-package-scripts.test.js.snap @@ -2,8 +2,6 @@ exports[`create alice-bobbi module with example, with \`exampleFileLinkage: true\` then recover from missing scripts in example package.json 1`] = ` Array [ - "* execa.commandSync command: react-native --version options: {\\"stdio\\":\\"inherit\\"} -", "* execa.commandSync command: yarn --version options: {\\"stdio\\":\\"inherit\\"} ", "* ensureDir dir: react-native-alice-bobbi @@ -788,13 +786,21 @@ content: <<<<<<<< ======== >>>>>>>> ", - "* execa.commandSync command: react-native init example --version react-native@latest options: {\\"cwd\\":\\"./react-native-alice-bobbi\\",\\"stdio\\":\\"inherit\\"} -", - "* ensureDir dir: react-native-alice-bobbi/scripts/ + Object { + "call": "reactNativeInit", + "nameArray": Array [ + "example", + ], + "options": Object { + "directory": "react-native-alice-bobbi/example", + "template": "react-native@latest", + }, + }, + "* ensureDir dir: .../react-native-alice-bobbi/scripts/ ", - "* ensureDir dir: react-native-alice-bobbi/example/ + "* ensureDir dir: .../react-native-alice-bobbi/example/ ", - "* outputFile name: react-native-alice-bobbi/scripts/examples_postinstall.js + "* outputFile name: .../react-native-alice-bobbi/scripts/examples_postinstall.js content: -------- #!/usr/bin/env node @@ -911,7 +917,7 @@ content: <<<<<<<< ======== >>>>>>>> ", - "* outputFile name: react-native-alice-bobbi/example/App.js + "* outputFile name: .../react-native-alice-bobbi/example/App.js content: -------- /** @@ -976,11 +982,11 @@ const styles = StyleSheet.create({ ", Object { "call": "fs.readFileSync", - "jsonFilePath": "./react-native-alice-bobbi/example/package.json", + "jsonFilePath": ".../react-native-alice-bobbi/example/package.json", }, Object { "call": "fs.writeFileSync", - "filePath": "./react-native-alice-bobbi/example/package.json", + "filePath": ".../react-native-alice-bobbi/example/package.json", "json": "{ \\"name\\": \\"example\\", \\"version\\": \\"0.0.1\\", @@ -999,11 +1005,11 @@ const styles = StyleSheet.create({ "spaces": 2, }, }, - "* execa.commandSync command: yarn add file:../ options: {\\"cwd\\":\\"./react-native-alice-bobbi/example\\",\\"stdio\\":\\"inherit\\"} + "* execa.commandSync command: yarn add file:../ options: {\\"cwd\\":\\".../react-native-alice-bobbi/example\\",\\"stdio\\":\\"inherit\\"} ", - "* execa.commandSync command: pod --version options: {\\"cwd\\":\\"./react-native-alice-bobbi/example/ios\\",\\"stdio\\":\\"inherit\\"} + "* execa.commandSync command: pod --version options: {\\"cwd\\":\\".../react-native-alice-bobbi/example/ios\\",\\"stdio\\":\\"inherit\\"} ", - "* execa.commandSync command: pod install options: {\\"cwd\\":\\"./react-native-alice-bobbi/example/ios\\",\\"stdio\\":\\"inherit\\"} + "* execa.commandSync command: pod install options: {\\"cwd\\":\\".../react-native-alice-bobbi/example/ios\\",\\"stdio\\":\\"inherit\\"} ", ] `; diff --git a/tests/with-injection/create/with-example/with-null-options/with-null-prefix/__snapshots__/create-with-example-with-null-prefix.test.js.snap b/tests/with-injection/create/with-example/with-null-options/with-null-prefix/__snapshots__/create-with-example-with-null-prefix.test.js.snap index a93b92699..c6512227a 100644 --- a/tests/with-injection/create/with-example/with-null-options/with-null-prefix/__snapshots__/create-with-example-with-null-prefix.test.js.snap +++ b/tests/with-injection/create/with-example/with-null-options/with-null-prefix/__snapshots__/create-with-example-with-null-prefix.test.js.snap @@ -2,8 +2,6 @@ exports[`create alice-bobbi module with example, with prefix: null 1`] = ` Array [ - "* execa.commandSync command: react-native --version options: {\\"stdio\\":\\"inherit\\"} -", "* execa.commandSync command: yarn --version options: {\\"stdio\\":\\"inherit\\"} ", "* ensureDir dir: react-native-alice-bobbi @@ -788,13 +786,21 @@ content: <<<<<<<< ======== >>>>>>>> ", - "* execa.commandSync command: react-native init example --version react-native@latest options: {\\"cwd\\":\\"./react-native-alice-bobbi\\",\\"stdio\\":\\"inherit\\"} -", - "* ensureDir dir: react-native-alice-bobbi/example/ + Object { + "call": "reactNativeInit", + "nameArray": Array [ + "example", + ], + "options": Object { + "directory": "react-native-alice-bobbi/example", + "template": "react-native@latest", + }, + }, + "* ensureDir dir: .../react-native-alice-bobbi/example/ ", - "* ensureDir dir: react-native-alice-bobbi/example/ + "* ensureDir dir: .../react-native-alice-bobbi/example/ ", - "* outputFile name: react-native-alice-bobbi/example/metro.config.js + "* outputFile name: .../react-native-alice-bobbi/example/metro.config.js content: -------- // metro.config.js @@ -828,7 +834,7 @@ module.exports = { <<<<<<<< ======== >>>>>>>> ", - "* outputFile name: react-native-alice-bobbi/example/App.js + "* outputFile name: .../react-native-alice-bobbi/example/App.js content: -------- /** @@ -891,11 +897,11 @@ const styles = StyleSheet.create({ <<<<<<<< ======== >>>>>>>> ", - "* execa.commandSync command: yarn add link:../ options: {\\"cwd\\":\\"./react-native-alice-bobbi/example\\",\\"stdio\\":\\"inherit\\"} + "* execa.commandSync command: yarn add link:../ options: {\\"cwd\\":\\".../react-native-alice-bobbi/example\\",\\"stdio\\":\\"inherit\\"} ", - "* execa.commandSync command: pod --version options: {\\"cwd\\":\\"./react-native-alice-bobbi/example/ios\\",\\"stdio\\":\\"inherit\\"} + "* execa.commandSync command: pod --version options: {\\"cwd\\":\\".../react-native-alice-bobbi/example/ios\\",\\"stdio\\":\\"inherit\\"} ", - "* execa.commandSync command: pod install options: {\\"cwd\\":\\"./react-native-alice-bobbi/example/ios\\",\\"stdio\\":\\"inherit\\"} + "* execa.commandSync command: pod install options: {\\"cwd\\":\\".../react-native-alice-bobbi/example/ios\\",\\"stdio\\":\\"inherit\\"} ", ] `; diff --git a/tests/with-injection/create/with-example/with-options/__snapshots__/create-with-example-with-options.test.js.snap b/tests/with-injection/create/with-example/with-options/__snapshots__/create-with-example-with-options.test.js.snap index 463841841..02a40f98e 100644 --- a/tests/with-injection/create/with-example/with-options/__snapshots__/create-with-example-with-options.test.js.snap +++ b/tests/with-injection/create/with-example/with-options/__snapshots__/create-with-example-with-options.test.js.snap @@ -2,8 +2,6 @@ exports[`create alice-bobbi module with example, with config options including \`exampleFileLinkage: true\` 1`] = ` Array [ - "* execa.commandSync command: react-native --version options: {\\"stdio\\":\\"inherit\\"} -", "* execa.commandSync command: yarn --version options: {\\"stdio\\":\\"inherit\\"} ", "* ensureDir dir: react-native-alice-bobbi @@ -795,15 +793,23 @@ content: <<<<<<<< ======== >>>>>>>> ", - "* execa.commandSync command: react-native init test-demo --version react-native@0.60 options: {\\"cwd\\":\\"./react-native-alice-bobbi\\",\\"stdio\\":\\"inherit\\"} -", - "* ensureDir dir: react-native-alice-bobbi/scripts/ + Object { + "call": "reactNativeInit", + "nameArray": Array [ + "test-demo", + ], + "options": Object { + "directory": "react-native-alice-bobbi/test-demo", + "template": "react-native@0.60", + }, + }, + "* ensureDir dir: .../react-native-alice-bobbi/scripts/ ", - "* ensureDir dir: react-native-alice-bobbi/test-demo/ios/ + "* ensureDir dir: .../react-native-alice-bobbi/test-demo/ios/ ", - "* ensureDir dir: react-native-alice-bobbi/test-demo/ + "* ensureDir dir: .../react-native-alice-bobbi/test-demo/ ", - "* outputFile name: react-native-alice-bobbi/scripts/examples_postinstall.js + "* outputFile name: .../react-native-alice-bobbi/scripts/examples_postinstall.js content: -------- #!/usr/bin/env node @@ -920,7 +926,7 @@ content: <<<<<<<< ======== >>>>>>>> ", - "* outputFile name: react-native-alice-bobbi/test-demo/ios/Podfile + "* outputFile name: .../react-native-alice-bobbi/test-demo/ios/Podfile content: -------- platform :ios, '10.0' @@ -957,7 +963,7 @@ end <<<<<<<< ======== >>>>>>>> ", - "* outputFile name: react-native-alice-bobbi/test-demo/App.js + "* outputFile name: .../react-native-alice-bobbi/test-demo/App.js content: -------- /** @@ -1022,11 +1028,11 @@ const styles = StyleSheet.create({ ", Object { "call": "fs.readFileSync", - "jsonFilePath": "./react-native-alice-bobbi/test-demo/package.json", + "jsonFilePath": ".../react-native-alice-bobbi/test-demo/package.json", }, Object { "call": "fs.writeFileSync", - "filePath": "./react-native-alice-bobbi/test-demo/package.json", + "filePath": ".../react-native-alice-bobbi/test-demo/package.json", "json": "{ \\"name\\": \\"example\\", \\"scripts\\": { @@ -1045,11 +1051,11 @@ const styles = StyleSheet.create({ "spaces": 2, }, }, - "* execa.commandSync command: yarn add file:../ options: {\\"cwd\\":\\"./react-native-alice-bobbi/test-demo\\",\\"stdio\\":\\"inherit\\"} + "* execa.commandSync command: yarn add file:../ options: {\\"cwd\\":\\".../react-native-alice-bobbi/test-demo\\",\\"stdio\\":\\"inherit\\"} ", - "* execa.commandSync command: pod --version options: {\\"cwd\\":\\"./react-native-alice-bobbi/test-demo/ios\\",\\"stdio\\":\\"inherit\\"} + "* execa.commandSync command: pod --version options: {\\"cwd\\":\\".../react-native-alice-bobbi/test-demo/ios\\",\\"stdio\\":\\"inherit\\"} ", - "* execa.commandSync command: pod install options: {\\"cwd\\":\\"./react-native-alice-bobbi/test-demo/ios\\",\\"stdio\\":\\"inherit\\"} + "* execa.commandSync command: pod install options: {\\"cwd\\":\\".../react-native-alice-bobbi/test-demo/ios\\",\\"stdio\\":\\"inherit\\"} ", ] `; diff --git a/tests/with-mocks/cli/program/with-defaults/for-android/__snapshots__/cli-program-with-defaults-for-android.test.js.snap b/tests/with-mocks/cli/program/with-defaults/for-android/__snapshots__/cli-program-with-defaults-for-android.test.js.snap index 653911410..558e83fe2 100644 --- a/tests/with-mocks/cli/program/with-defaults/for-android/__snapshots__/cli-program-with-defaults-for-android.test.js.snap +++ b/tests/with-mocks/cli/program/with-defaults/for-android/__snapshots__/cli-program-with-defaults-for-android.test.js.snap @@ -191,7 +191,7 @@ Array [ "option": Object { "args": Array [ "--example-react-native-version [exampleReactNativeVersion]", - "React Native version for the generated example project", + "React Native template version for the generated example project, for example: react-native-tvos, react-native-tvos@0.62.2-1 (requires --tvos-enabled option); react-native@0.62", [Function], "react-native@latest", ], diff --git a/tests/with-mocks/cli/program/with-example/with-logging/__snapshots__/cli-program-with-example-with-logging.test.js.snap b/tests/with-mocks/cli/program/with-example/with-logging/__snapshots__/cli-program-with-example-with-logging.test.js.snap index ad4192e27..af50d82fc 100644 --- a/tests/with-mocks/cli/program/with-example/with-logging/__snapshots__/cli-program-with-example-with-logging.test.js.snap +++ b/tests/with-mocks/cli/program/with-example/with-logging/__snapshots__/cli-program-with-example-with-logging.test.js.snap @@ -191,7 +191,7 @@ Array [ "option": Object { "args": Array [ "--example-react-native-version [exampleReactNativeVersion]", - "React Native version for the generated example project", + "React Native template version for the generated example project, for example: react-native-tvos, react-native-tvos@0.62.2-1 (requires --tvos-enabled option); react-native@0.62", [Function], "react-native@latest", ], @@ -250,22 +250,6 @@ exampleReactNativeVersion: react-native@latest ", ], }, - Object { - "info": Array [ - "CREATE: Check for valid react-native-cli tool version, as needed to generate the example project", - ], - }, - Object { - "commandSync": "react-native --version", - "options": Object { - "stdio": "inherit", - }, - }, - Object { - "info": Array [ - "react-native --version ok", - ], - }, Object { "info": Array [ "CREATE: Check for valid Yarn CLI tool version, as needed to generate the example project", @@ -1058,24 +1042,27 @@ RCT_EXPORT_METHOD(sampleMethod:(NSString *)stringArgument numberParameter:(nonnu }, Object { "info": Array [ - "CREATE example app with the following command: react-native init example --version react-native@latest", + "CREATE example app with the following template: react-native@latest", ], }, Object { - "commandSync": "react-native init example --version react-native@latest", + "call": "reactNativeInit", + "nameArray": Array [ + "example", + ], "options": Object { - "cwd": "./react-native-test-package", - "stdio": "inherit", + "directory": "react-native-test-package/example", + "template": "react-native@latest", }, }, Object { - "ensureDir": "react-native-test-package/example/", + "ensureDir": ".../react-native-test-package/example/", }, Object { - "ensureDir": "react-native-test-package/example/", + "ensureDir": ".../react-native-test-package/example/", }, Object { - "outputFileName": "react-native-test-package/example/metro.config.js", + "outputFileName": ".../react-native-test-package/example/metro.config.js", "theContent": "// metro.config.js // // with multiple workarounds for this issue with symlinks: @@ -1107,7 +1094,7 @@ module.exports = { ", }, Object { - "outputFileName": "react-native-test-package/example/App.js", + "outputFileName": ".../react-native-test-package/example/App.js", "theContent": "/** * Sample React Native App * @@ -1175,31 +1162,31 @@ const styles = StyleSheet.create({ Object { "commandSync": "yarn add link:../", "options": Object { - "cwd": "./react-native-test-package/example", + "cwd": ".../react-native-test-package/example", "stdio": "inherit", }, }, Object { "info": Array [ - "check for valid pod version in ./react-native-test-package/example/ios", + "check for valid pod version in .../react-native-test-package/example/ios", ], }, Object { "commandSync": "pod --version", "options": Object { - "cwd": "./react-native-test-package/example/ios", + "cwd": ".../react-native-test-package/example/ios", "stdio": "inherit", }, }, Object { "info": Array [ - "running pod install in ./react-native-test-package/example/ios", + "running pod install in .../react-native-test-package/example/ios", ], }, Object { "commandSync": "pod install", "options": Object { - "cwd": "./react-native-test-package/example/ios", + "cwd": ".../react-native-test-package/example/ios", "stdio": "inherit", }, }, diff --git a/tests/with-mocks/cli/program/with-missing-args/__snapshots__/cli-program-with-missing-args.test.js.snap b/tests/with-mocks/cli/program/with-missing-args/__snapshots__/cli-program-with-missing-args.test.js.snap index 47bd28346..202cd8c5d 100644 --- a/tests/with-mocks/cli/program/with-missing-args/__snapshots__/cli-program-with-missing-args.test.js.snap +++ b/tests/with-mocks/cli/program/with-missing-args/__snapshots__/cli-program-with-missing-args.test.js.snap @@ -189,7 +189,7 @@ Array [ "option": Object { "args": Array [ "--example-react-native-version [exampleReactNativeVersion]", - "React Native version for the generated example project", + "React Native template version for the generated example project, for example: react-native-tvos, react-native-tvos@0.62.2-1 (requires --tvos-enabled option); react-native@0.62", [Function], "react-native@latest", ], diff --git a/tests/with-mocks/lib/create/with-example/with-logging/with-defaults/__snapshots__/create-with-example-with-defaults.test.js.snap b/tests/with-mocks/lib/create/with-example/with-logging/with-defaults/__snapshots__/create-with-example-with-defaults.test.js.snap index fba765c81..a17e5803b 100644 --- a/tests/with-mocks/lib/create/with-example/with-logging/with-defaults/__snapshots__/create-with-example-with-defaults.test.js.snap +++ b/tests/with-mocks/lib/create/with-example/with-logging/with-defaults/__snapshots__/create-with-example-with-defaults.test.js.snap @@ -36,22 +36,6 @@ exampleReactNativeVersion: react-native@latest ", ], }, - Object { - "info": Array [ - "CREATE: Check for valid react-native-cli tool version, as needed to generate the example project", - ], - }, - Object { - "commandSync": "react-native --version", - "options": Object { - "stdio": "inherit", - }, - }, - Object { - "info": Array [ - "react-native --version ok", - ], - }, Object { "info": Array [ "CREATE: Check for valid Yarn CLI tool version, as needed to generate the example project", @@ -844,24 +828,27 @@ RCT_EXPORT_METHOD(sampleMethod:(NSString *)stringArgument numberParameter:(nonnu }, Object { "info": Array [ - "CREATE example app with the following command: react-native init example --version react-native@latest", + "CREATE example app with the following template: react-native@latest", ], }, Object { - "commandSync": "react-native init example --version react-native@latest", + "call": "reactNativeInit", + "nameArray": Array [ + "example", + ], "options": Object { - "cwd": "./react-native-alice-bobbi", - "stdio": "inherit", + "directory": "react-native-alice-bobbi/example", + "template": "react-native@latest", }, }, Object { - "ensureDir": "react-native-alice-bobbi/example/", + "ensureDir": ".../react-native-alice-bobbi/example/", }, Object { - "ensureDir": "react-native-alice-bobbi/example/", + "ensureDir": ".../react-native-alice-bobbi/example/", }, Object { - "outputFileName": "react-native-alice-bobbi/example/metro.config.js", + "outputFileName": ".../react-native-alice-bobbi/example/metro.config.js", "theContent": "// metro.config.js // // with multiple workarounds for this issue with symlinks: @@ -893,7 +880,7 @@ module.exports = { ", }, Object { - "outputFileName": "react-native-alice-bobbi/example/App.js", + "outputFileName": ".../react-native-alice-bobbi/example/App.js", "theContent": "/** * Sample React Native App * @@ -961,31 +948,31 @@ const styles = StyleSheet.create({ Object { "commandSync": "yarn add link:../", "options": Object { - "cwd": "./react-native-alice-bobbi/example", + "cwd": ".../react-native-alice-bobbi/example", "stdio": "inherit", }, }, Object { "info": Array [ - "check for valid pod version in ./react-native-alice-bobbi/example/ios", + "check for valid pod version in .../react-native-alice-bobbi/example/ios", ], }, Object { "commandSync": "pod --version", "options": Object { - "cwd": "./react-native-alice-bobbi/example/ios", + "cwd": ".../react-native-alice-bobbi/example/ios", "stdio": "inherit", }, }, Object { "info": Array [ - "running pod install in ./react-native-alice-bobbi/example/ios", + "running pod install in .../react-native-alice-bobbi/example/ios", ], }, Object { "commandSync": "pod install", "options": Object { - "cwd": "./react-native-alice-bobbi/example/ios", + "cwd": ".../react-native-alice-bobbi/example/ios", "stdio": "inherit", }, }, diff --git a/tests/with-mocks/lib/create/with-example/with-logging/with-error/__snapshots__/with-yarn-error-logging.test.js.snap b/tests/with-mocks/lib/create/with-example/with-logging/with-error/__snapshots__/with-yarn-error-logging.test.js.snap index 1fe523d1e..38a8cce26 100644 --- a/tests/with-mocks/lib/create/with-example/with-logging/with-error/__snapshots__/with-yarn-error-logging.test.js.snap +++ b/tests/with-mocks/lib/create/with-example/with-logging/with-error/__snapshots__/with-yarn-error-logging.test.js.snap @@ -36,22 +36,6 @@ exampleReactNativeVersion: react-native@latest ", ], }, - Object { - "info": Array [ - "CREATE: Check for valid react-native-cli tool version, as needed to generate the example project", - ], - }, - Object { - "commandSync": "react-native --version", - "options": Object { - "stdio": "inherit", - }, - }, - Object { - "info": Array [ - "react-native --version ok", - ], - }, Object { "info": Array [ "CREATE: Check for valid Yarn CLI tool version, as needed to generate the example project", @@ -844,24 +828,27 @@ RCT_EXPORT_METHOD(sampleMethod:(NSString *)stringArgument numberParameter:(nonnu }, Object { "info": Array [ - "CREATE example app with the following command: react-native init example --version react-native@latest", + "CREATE example app with the following template: react-native@latest", ], }, Object { - "commandSync": "react-native init example --version react-native@latest", + "call": "reactNativeInit", + "nameArray": Array [ + "example", + ], "options": Object { - "cwd": "./react-native-alice-bobbi", - "stdio": "inherit", + "directory": "react-native-alice-bobbi/example", + "template": "react-native@latest", }, }, Object { - "ensureDir": "react-native-alice-bobbi/example/", + "ensureDir": ".../react-native-alice-bobbi/example/", }, Object { - "ensureDir": "react-native-alice-bobbi/example/", + "ensureDir": ".../react-native-alice-bobbi/example/", }, Object { - "outputFileName": "react-native-alice-bobbi/example/metro.config.js", + "outputFileName": ".../react-native-alice-bobbi/example/metro.config.js", "theContent": "// metro.config.js // // with multiple workarounds for this issue with symlinks: @@ -893,7 +880,7 @@ module.exports = { ", }, Object { - "outputFileName": "react-native-alice-bobbi/example/App.js", + "outputFileName": ".../react-native-alice-bobbi/example/App.js", "theContent": "/** * Sample React Native App * @@ -961,7 +948,7 @@ const styles = StyleSheet.create({ Object { "commandSync": "yarn add link:../", "options": Object { - "cwd": "./react-native-alice-bobbi/example", + "cwd": ".../react-native-alice-bobbi/example", "stdio": "inherit", }, }, diff --git a/tests/with-mocks/lib/create/with-example/with-logging/with-null-options/with-null-prefix/__snapshots__/create-with-example-with-options.test.js.snap b/tests/with-mocks/lib/create/with-example/with-logging/with-null-options/with-null-prefix/__snapshots__/create-with-example-with-options.test.js.snap index 92f413676..3f291b3d7 100644 --- a/tests/with-mocks/lib/create/with-example/with-logging/with-null-options/with-null-prefix/__snapshots__/create-with-example-with-options.test.js.snap +++ b/tests/with-mocks/lib/create/with-example/with-logging/with-null-options/with-null-prefix/__snapshots__/create-with-example-with-options.test.js.snap @@ -36,22 +36,6 @@ exampleReactNativeVersion: react-native@latest ", ], }, - Object { - "info": Array [ - "CREATE: Check for valid react-native-cli tool version, as needed to generate the example project", - ], - }, - Object { - "commandSync": "react-native --version", - "options": Object { - "stdio": "inherit", - }, - }, - Object { - "info": Array [ - "react-native --version ok", - ], - }, Object { "info": Array [ "CREATE: Check for valid Yarn CLI tool version, as needed to generate the example project", @@ -844,24 +828,27 @@ RCT_EXPORT_METHOD(sampleMethod:(NSString *)stringArgument numberParameter:(nonnu }, Object { "info": Array [ - "CREATE example app with the following command: react-native init example --version react-native@latest", + "CREATE example app with the following template: react-native@latest", ], }, Object { - "commandSync": "react-native init example --version react-native@latest", + "call": "reactNativeInit", + "nameArray": Array [ + "example", + ], "options": Object { - "cwd": "./react-native-alice-bobbi", - "stdio": "inherit", + "directory": "react-native-alice-bobbi/example", + "template": "react-native@latest", }, }, Object { - "ensureDir": "react-native-alice-bobbi/example/", + "ensureDir": ".../react-native-alice-bobbi/example/", }, Object { - "ensureDir": "react-native-alice-bobbi/example/", + "ensureDir": ".../react-native-alice-bobbi/example/", }, Object { - "outputFileName": "react-native-alice-bobbi/example/metro.config.js", + "outputFileName": ".../react-native-alice-bobbi/example/metro.config.js", "theContent": "// metro.config.js // // with multiple workarounds for this issue with symlinks: @@ -893,7 +880,7 @@ module.exports = { ", }, Object { - "outputFileName": "react-native-alice-bobbi/example/App.js", + "outputFileName": ".../react-native-alice-bobbi/example/App.js", "theContent": "/** * Sample React Native App * @@ -961,31 +948,31 @@ const styles = StyleSheet.create({ Object { "commandSync": "yarn add link:../", "options": Object { - "cwd": "./react-native-alice-bobbi/example", + "cwd": ".../react-native-alice-bobbi/example", "stdio": "inherit", }, }, Object { "info": Array [ - "check for valid pod version in ./react-native-alice-bobbi/example/ios", + "check for valid pod version in .../react-native-alice-bobbi/example/ios", ], }, Object { "commandSync": "pod --version", "options": Object { - "cwd": "./react-native-alice-bobbi/example/ios", + "cwd": ".../react-native-alice-bobbi/example/ios", "stdio": "inherit", }, }, Object { "info": Array [ - "running pod install in ./react-native-alice-bobbi/example/ios", + "running pod install in .../react-native-alice-bobbi/example/ios", ], }, Object { "commandSync": "pod install", "options": Object { - "cwd": "./react-native-alice-bobbi/example/ios", + "cwd": ".../react-native-alice-bobbi/example/ios", "stdio": "inherit", }, }, diff --git a/tests/with-mocks/lib/create/with-example/with-logging/with-options/__snapshots__/create-with-example-with-options.test.js.snap b/tests/with-mocks/lib/create/with-example/with-logging/with-options/__snapshots__/create-with-example-with-options.test.js.snap index abfeb62b5..a19abfbd2 100644 --- a/tests/with-mocks/lib/create/with-example/with-logging/with-options/__snapshots__/create-with-example-with-options.test.js.snap +++ b/tests/with-mocks/lib/create/with-example/with-logging/with-options/__snapshots__/create-with-example-with-options.test.js.snap @@ -30,22 +30,6 @@ exampleReactNativeVersion: react-native@npm:react-native-tvos ", ], }, - Object { - "info": Array [ - "CREATE: Check for valid react-native-cli tool version, as needed to generate the example project", - ], - }, - Object { - "commandSync": "react-native --version", - "options": Object { - "stdio": "inherit", - }, - }, - Object { - "info": Array [ - "react-native --version ok", - ], - }, Object { "info": Array [ "CREATE: Check for valid Yarn CLI tool version, as needed to generate the example project", @@ -838,24 +822,27 @@ RCT_EXPORT_METHOD(sampleMethod:(NSString *)stringArgument numberParameter:(nonnu }, Object { "info": Array [ - "CREATE example app with the following command: react-native init demo --version react-native@npm:react-native-tvos", + "CREATE example app with the following template: react-native@npm:react-native-tvos", ], }, Object { - "commandSync": "react-native init demo --version react-native@npm:react-native-tvos", + "call": "reactNativeInit", + "nameArray": Array [ + "demo", + ], "options": Object { - "cwd": "./react-native-alice-bobbi", - "stdio": "inherit", + "directory": "react-native-alice-bobbi/demo", + "template": "react-native@npm:react-native-tvos", }, }, Object { - "ensureDir": "react-native-alice-bobbi/scripts/", + "ensureDir": ".../react-native-alice-bobbi/scripts/", }, Object { - "ensureDir": "react-native-alice-bobbi/demo/", + "ensureDir": ".../react-native-alice-bobbi/demo/", }, Object { - "outputFileName": "react-native-alice-bobbi/scripts/examples_postinstall.js", + "outputFileName": ".../react-native-alice-bobbi/scripts/examples_postinstall.js", "theContent": "#!/usr/bin/env node /* @@ -970,7 +957,7 @@ RCT_EXPORT_METHOD(sampleMethod:(NSString *)stringArgument numberParameter:(nonnu ", }, Object { - "outputFileName": "react-native-alice-bobbi/demo/App.js", + "outputFileName": ".../react-native-alice-bobbi/demo/App.js", "theContent": "/** * Sample React Native App * @@ -1036,7 +1023,7 @@ const styles = StyleSheet.create({ ], }, Object { - "readFileSyncFromPath": "./react-native-alice-bobbi/demo/package.json", + "readFileSyncFromPath": ".../react-native-alice-bobbi/demo/package.json", }, Object { "json": "{ @@ -1056,7 +1043,7 @@ const styles = StyleSheet.create({ }, "spaces": 2, }, - "writeFileSyncToPath": "./react-native-alice-bobbi/demo/package.json", + "writeFileSyncToPath": ".../react-native-alice-bobbi/demo/package.json", }, Object { "info": Array [ @@ -1066,31 +1053,31 @@ const styles = StyleSheet.create({ Object { "commandSync": "yarn add file:../", "options": Object { - "cwd": "./react-native-alice-bobbi/demo", + "cwd": ".../react-native-alice-bobbi/demo", "stdio": "inherit", }, }, Object { "info": Array [ - "check for valid pod version in ./react-native-alice-bobbi/demo/ios", + "check for valid pod version in .../react-native-alice-bobbi/demo/ios", ], }, Object { "commandSync": "pod --version", "options": Object { - "cwd": "./react-native-alice-bobbi/demo/ios", + "cwd": ".../react-native-alice-bobbi/demo/ios", "stdio": "inherit", }, }, Object { "info": Array [ - "running pod install in ./react-native-alice-bobbi/demo/ios", + "running pod install in .../react-native-alice-bobbi/demo/ios", ], }, Object { "commandSync": "pod install", "options": Object { - "cwd": "./react-native-alice-bobbi/demo/ios", + "cwd": ".../react-native-alice-bobbi/demo/ios", "stdio": "inherit", }, },