|
| 1 | +format_version: "23" |
| 2 | +default_step_lib_source: https://github.com/bitrise-io/bitrise-steplib.git |
| 3 | +project_type: other |
| 4 | + |
| 5 | +meta: |
| 6 | + bitrise.io: |
| 7 | + stack: linux-docker-android-22.04 |
| 8 | + machine_type_id: g2.linux.medium |
| 9 | + |
| 10 | +app: |
| 11 | + envs: |
| 12 | + - E2E_RUN_COUNT: "2" |
| 13 | + - E2E_STRICT: "false" |
| 14 | + - E2E_BROWSERSTACK_API_RETRIES: "1" |
| 15 | + - E2E_BROWSERSTACK_TIMEOUT_SECONDS: "1800" |
| 16 | + - E2E_BROWSERSTACK_POLL_SECONDS: "30" |
| 17 | + - E2E_IOS_EXPORT_METHOD: development |
| 18 | + - E2E_PACKAGE_COMMAND_TIMEOUT_SECONDS: "300" |
| 19 | + - E2E_RUBY_INSTALL_TIMEOUT_SECONDS: "1800" |
| 20 | + |
| 21 | +pipelines: |
| 22 | + e2e: |
| 23 | + workflows: |
| 24 | + e2e-package-suite: {} |
| 25 | + e2e-build-react-native-ios: {} |
| 26 | + e2e-build-react-native-android: {} |
| 27 | + e2e-run-browserstack: |
| 28 | + depends_on: |
| 29 | + - e2e-package-suite |
| 30 | + - e2e-build-react-native-ios |
| 31 | + - e2e-build-react-native-android |
| 32 | + parallel: $E2E_RUN_COUNT |
| 33 | + e2e-report: |
| 34 | + depends_on: |
| 35 | + - e2e-run-browserstack |
| 36 | + should_always_run: workflow |
| 37 | + |
| 38 | +workflows: |
| 39 | + e2e-package-suite: |
| 40 | + steps: |
| 41 | + - git-clone@8: {} |
| 42 | + - script@1: |
| 43 | + title: Validate E2E matrix and create suite placeholder |
| 44 | + inputs: |
| 45 | + - content: |- |
| 46 | + set -euo pipefail |
| 47 | + source e2e/scripts/bitrise_ci_helpers |
| 48 | + e2e_prepare_ruby |
| 49 | + e2e_run_with_timeout "${E2E_PACKAGE_COMMAND_TIMEOUT_SECONDS:-300}" ruby e2e/scripts/e2e_matrix validate |
| 50 | + e2e_log "Expanding E2E matrix" |
| 51 | + e2e_run_with_timeout "${E2E_PACKAGE_COMMAND_TIMEOUT_SECONDS:-300}" ruby e2e/scripts/e2e_matrix expand > "$BITRISE_DEPLOY_DIR/e2e-matrix.json" |
| 52 | + e2e_log "Creating Maestro suite placeholder" |
| 53 | + mkdir -p "$BITRISE_DEPLOY_DIR/e2e" |
| 54 | + echo "Phase 2 placeholder for BrowserStack Maestro suite zip" > "$BITRISE_DEPLOY_DIR/e2e/maestro-suite.zip" |
| 55 | + e2e_log "Publishing Maestro suite path" |
| 56 | + envman add --key E2E_MAESTRO_SUITE_ZIP --value "$BITRISE_DEPLOY_DIR/e2e/maestro-suite.zip" |
| 57 | + - deploy-to-bitrise-io@2: |
| 58 | + inputs: |
| 59 | + - pipeline_intermediate_files: |- |
| 60 | + $E2E_MAESTRO_SUITE_ZIP:E2E_MAESTRO_SUITE_ZIP |
| 61 | + $BITRISE_DEPLOY_DIR/e2e-matrix.json:E2E_MATRIX_JSON |
| 62 | +
|
| 63 | + e2e-build-react-native-ios: |
| 64 | + steps: |
| 65 | + - git-clone@8: {} |
| 66 | + - restore-cache@1: |
| 67 | + inputs: |
| 68 | + - key: |- |
| 69 | + rn-ios-{{ checksum "platforms/react-native/pnpm-lock.yaml" }}-{{ checksum "platforms/react-native/sample/ios/Podfile.lock" }} |
| 70 | + - script@1: |
| 71 | + title: Create React Native iOS artifact placeholder |
| 72 | + inputs: |
| 73 | + - content: |- |
| 74 | + set -euo pipefail |
| 75 | + mkdir -p "$BITRISE_DEPLOY_DIR/e2e" |
| 76 | + echo "Phase 2 placeholder for React Native iOS IPA" > "$BITRISE_DEPLOY_DIR/e2e/react-native-ios.ipa" |
| 77 | + envman add --key E2E_REACT_NATIVE_IOS_APP_PATH --value "$BITRISE_DEPLOY_DIR/e2e/react-native-ios.ipa" |
| 78 | + - deploy-to-bitrise-io@2: |
| 79 | + inputs: |
| 80 | + - pipeline_intermediate_files: |- |
| 81 | + $E2E_REACT_NATIVE_IOS_APP_PATH:E2E_REACT_NATIVE_IOS_APP_PATH |
| 82 | + - save-cache@1: |
| 83 | + inputs: |
| 84 | + - key: |- |
| 85 | + rn-ios-{{ checksum "platforms/react-native/pnpm-lock.yaml" }}-{{ checksum "platforms/react-native/sample/ios/Podfile.lock" }} |
| 86 | + - paths: |- |
| 87 | + platforms/react-native/node_modules |
| 88 | + platforms/react-native/sample/ios/Pods |
| 89 | +
|
| 90 | + e2e-build-react-native-android: |
| 91 | + steps: |
| 92 | + - git-clone@8: {} |
| 93 | + - restore-cache@1: |
| 94 | + inputs: |
| 95 | + - key: |- |
| 96 | + rn-android-{{ checksum "platforms/react-native/pnpm-lock.yaml" }}-{{ checksum "platforms/react-native/sample/android/**/*.gradle*" }} |
| 97 | + - script@1: |
| 98 | + title: Create React Native Android artifact placeholder |
| 99 | + inputs: |
| 100 | + - content: |- |
| 101 | + set -euo pipefail |
| 102 | + mkdir -p "$BITRISE_DEPLOY_DIR/e2e" |
| 103 | + echo "Phase 2 placeholder for React Native Android APK" > "$BITRISE_DEPLOY_DIR/e2e/react-native-android.apk" |
| 104 | + envman add --key E2E_REACT_NATIVE_ANDROID_APP_PATH --value "$BITRISE_DEPLOY_DIR/e2e/react-native-android.apk" |
| 105 | + - deploy-to-bitrise-io@2: |
| 106 | + inputs: |
| 107 | + - pipeline_intermediate_files: |- |
| 108 | + $E2E_REACT_NATIVE_ANDROID_APP_PATH:E2E_REACT_NATIVE_ANDROID_APP_PATH |
| 109 | + - save-cache@1: |
| 110 | + inputs: |
| 111 | + - key: |- |
| 112 | + rn-android-{{ checksum "platforms/react-native/pnpm-lock.yaml" }}-{{ checksum "platforms/react-native/sample/android/**/*.gradle*" }} |
| 113 | + - paths: |- |
| 114 | + platforms/react-native/node_modules |
| 115 | + ~/.gradle/caches |
| 116 | + ~/.gradle/wrapper |
| 117 | +
|
| 118 | + e2e-run-browserstack: |
| 119 | + steps: |
| 120 | + - git-clone@8: {} |
| 121 | + - pull-intermediate-files@1: |
| 122 | + inputs: |
| 123 | + - artifact_sources: |- |
| 124 | + e2e-package-suite |
| 125 | + e2e-build-react-native-* |
| 126 | + - script@1: |
| 127 | + title: Resolve E2E matrix row placeholder |
| 128 | + inputs: |
| 129 | + - content: |- |
| 130 | + set -euo pipefail |
| 131 | + source e2e/scripts/bitrise_ci_helpers |
| 132 | + e2e_prepare_ruby |
| 133 | + run_index="${BITRISE_IO_PARALLEL_INDEX:-0}" |
| 134 | + mkdir -p "$BITRISE_DEPLOY_DIR/e2e/results" |
| 135 | + e2e_log "Resolving E2E matrix row ${run_index}" |
| 136 | + e2e_run_with_timeout "${E2E_PACKAGE_COMMAND_TIMEOUT_SECONDS:-300}" ruby e2e/scripts/e2e_matrix expand --index "$run_index" > "$BITRISE_DEPLOY_DIR/e2e/results/run-${run_index}.json" |
| 137 | + - deploy-to-bitrise-io@2: |
| 138 | + inputs: |
| 139 | + - pipeline_intermediate_files: |- |
| 140 | + $BITRISE_DEPLOY_DIR/e2e/results:E2E_BROWSERSTACK_RESULTS_DIR |
| 141 | +
|
| 142 | + e2e-report: |
| 143 | + steps: |
| 144 | + - git-clone@8: {} |
| 145 | + - pull-intermediate-files@1: |
| 146 | + inputs: |
| 147 | + - artifact_sources: |- |
| 148 | + e2e-run-browserstack |
| 149 | + - script@1: |
| 150 | + title: Placeholder E2E report |
| 151 | + inputs: |
| 152 | + - content: |- |
| 153 | + set -euo pipefail |
| 154 | + echo "Phase 2 placeholder for aggregate E2E reporting" |
0 commit comments