Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

2 stage builds #1997

Merged
merged 6 commits into from
Aug 14, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
File renamed without changes.
File renamed without changes.
107 changes: 107 additions & 0 deletions .buildkite/basic/react-native-android-pipeline.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,107 @@
steps:

- group: "React Native (Android) Tests"
steps:
#
# Android builder
#
- label: ":docker: Build RN Android Builder image"
key: "android-builder-image"
timeout_in_minutes: 30
plugins:
- docker-compose#v4.12.0:
build: react-native-android-builder
image-repository: 855461928731.dkr.ecr.us-west-1.amazonaws.com/js
cache-from: react-native-android-builder:855461928731.dkr.ecr.us-west-1.amazonaws.com/js:ci-${BRANCH_NAME}
- docker-compose#v4.12.0:
push: react-native-android-builder:855461928731.dkr.ecr.us-west-1.amazonaws.com/js:ci-${BRANCH_NAME}

#
# Test fixtures
#
- label: ":android: Build RN 0.72 (Old Arch) apk"
key: "rn-0-72-old-arch-apk"
depends_on:
- "android-builder-image"
timeout_in_minutes: 60
env:
REACT_NATIVE_VERSION: "rn0.72"
RN_NEW_ARCH: "false"
ARTEFACT_NAME: "rn0.72-old-arch"
plugins:
- docker-compose#v4.12.0:
pull: react-native-android-builder
run: react-native-android-builder
artifact_paths:
- build/rn0.72-old-arch.apk

- label: ":android: Build RN 0.72 (New Arch) apk"
key: "rn-0-72-new-arch-apk"
depends_on:
- "android-builder-image"
timeout_in_minutes: 60
env:
REACT_NATIVE_VERSION: "rn0.72"
RN_NEW_ARCH: "true"
ARTEFACT_NAME: "rn0.72-new-arch"
plugins:
- docker-compose#v4.12.0:
pull: react-native-android-builder
run: react-native-android-builder
artifact_paths:
- build/rn0.72-new-arch.apk

#
# End-to-end tests
#
- label: ":bitbar: :android: RN 0.72 (Old Arch) Android 12 end-to-end tests"
depends_on: "rn-0-72-old-arch-apk"
timeout_in_minutes: 60
plugins:
artifacts#v1.9.0:
download: "build/rn0.72-old-arch.apk"
upload: ./test/react-native/maze_output/**/*
docker-compose#v4.7.0:
pull: react-native-maze-runner
run: react-native-maze-runner
service-ports: true
command:
- --app=build/rn0.72-old-arch.apk
- --farm=bb
- --device=ANDROID_12
- --a11y-locator
- --fail-fast
- --no-tunnel
- --aws-public-ip
env:
SKIP_NAVIGATION_SCENARIOS: "true"
HERMES: "true"
concurrency: 25
concurrency_group: "bitbar-app"
concurrency_method: eager

- label: ":bitbar: :android: RN 0.72 (New Arch) Android 12 end-to-end tests"
depends_on: "rn-0-72-new-arch-apk"
timeout_in_minutes: 60
plugins:
artifacts#v1.9.0:
download: "build/rn0.72-new-arch.apk"
upload: ./test/react-native/maze_output/**/*
docker-compose#v4.7.0:
pull: react-native-maze-runner
run: react-native-maze-runner
service-ports: true
command:
- --app=build/rn0.72-new-arch.apk
- --farm=bb
- --device=ANDROID_12
- --a11y-locator
- --fail-fast
- --no-tunnel
- --aws-public-ip
env:
SKIP_NAVIGATION_SCENARIOS: "true"
HERMES: "true"
concurrency: 25
concurrency_group: "bitbar-app"
concurrency_method: eager
90 changes: 90 additions & 0 deletions .buildkite/basic/react-native-ios-pipeline.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
steps:

- group: "React Native (iOS) Tests"
steps:

#
# Test fixtures
#
- label: ":ios: Build RN 0.72 (Old Arch) ipa"
key: "rn-0-72-old-arch-ipa"
timeout_in_minutes: 60
agents:
queue: "opensource-arm-mac-cocoa-12"
env:
REACT_NATIVE_VERSION: "rn0.72"
LANG: "en_US.UTF-8"
DEVELOPER_DIR: "/Applications/Xcode14.app"
RCT_NEW_ARCH_ENABLED: "0"
ARTEFACT_NAME: "rn0.72-old-arch"
artifact_paths: build/rn0.72-old-arch.ipa
commands:
- npm run test:build-react-native-ios

- label: ":ios: Build RN 0.72 (New Arch) ipa"
key: "rn-0-72-new-arch-ipa"
timeout_in_minutes: 60
agents:
queue: "opensource-arm-mac-cocoa-12"
env:
REACT_NATIVE_VERSION: "rn0.72"
LANG: "en_US.UTF-8"
DEVELOPER_DIR: "/Applications/Xcode14.app"
RCT_NEW_ARCH_ENABLED: "1"
ARTEFACT_NAME: "rn0.72-new-arch"
artifact_paths: build/rn0.72-new-arch.ipa
commands:
- npm run test:build-react-native-ios

#
# End-to-end tests
#
- label: ":ios: RN 0.72 (Old Arch) iOS 14 end-to-end tests"
depends_on: "rn-0-72-old-arch-ipa"
timeout_in_minutes: 60
plugins:
artifacts#v1.5.0:
download: "build/rn0.72-old-arch.ipa"
upload: ./test/react-native/maze_output/**/*
docker-compose#v4.12.0:
pull: react-native-maze-runner
run: react-native-maze-runner
use-aliases: true
command:
- --app=build/rn0.72-old-arch.ipa
- --farm=bs
- --device=IOS_14
- --a11y-locator
- --appium-version=1.18.0
- --fail-fast
env:
SKIP_NAVIGATION_SCENARIOS: "true"
HERMES: "true"
concurrency: 5
concurrency_group: "browserstack-app"
concurrency_method: eager

- label: ":ios: RN 0.72 (New Arch) iOS 14 end-to-end tests"
depends_on: "rn-0-72-new-arch-ipa"
timeout_in_minutes: 60
plugins:
artifacts#v1.5.0:
download: "build/rn0.72-new-arch.ipa"
upload: ./test/react-native/maze_output/**/*
docker-compose#v4.12.0:
pull: react-native-maze-runner
run: react-native-maze-runner
use-aliases: true
command:
- --app=build/rn0.72-new-arch.ipa
- --farm=bs
- --device=IOS_14
- --a11y-locator
- --appium-version=1.18.0
- --fail-fast
env:
SKIP_NAVIGATION_SCENARIOS: "true"
HERMES: "true"
concurrency: 5
concurrency_group: "browserstack-app"
concurrency_method: eager
7 changes: 7 additions & 0 deletions .buildkite/full/block.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
steps:
- block: 'Trigger a full build'
key: 'trigger-full-build'

- label: 'Upload the full test pipeline'
depends_on: 'trigger-full-build'
command: buildkite-agent pipeline upload .buildkite/full/pipeline.full.yml
56 changes: 56 additions & 0 deletions .buildkite/full/pipeline.full.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
steps:

#
# Upload full React Native pipelines
#
- label: ":large_blue_circle: :large_blue_circle: :large_blue_circle: FULL REACT NATIVE (ANDROID) STEPS :large_blue_circle: :large_blue_circle: :large_blue_circle:"
commands:
- buildkite-agent pipeline upload .buildkite/full/react-native-android-pipeline.full.yml

- label: ":large_blue_circle: :large_blue_circle: :large_blue_circle: FULL REACT NATIVE (IOS) STEPS :large_blue_circle: :large_blue_circle: :large_blue_circle:"
commands:
- buildkite-agent pipeline upload .buildkite/full/react-native-ios-pipeline.full.yml

- label: ":large_blue_circle: :large_blue_circle: :large_blue_circle: REACT NATIVE CLI STEPS :large_blue_circle: :large_blue_circle: :large_blue_circle:"
depends_on:
- "publish-js"
- "android-builder-base"
commands:
- buildkite-agent pipeline upload .buildkite/full/react-native-cli-pipeline.full.yml

#
# Trigger Expo pipelines
#
- label: "@bugsnag/expo latest"
depends_on: "publish-js"
trigger: "bugsnag-expo"
build:
# don't specify 'branch' here so we build the default branch in the expo
# repo, which should be the most up-to-date @bugsnag/expo version
env:
BUGSNAG_JS_BRANCH: "${BUILDKITE_BRANCH}"
BUGSNAG_JS_COMMIT: "${BUILDKITE_COMMIT}"
# a branch name that's safe to use as a docker cache identifier
BUGSNAG_JS_CACHE_SAFE_BRANCH_NAME: "${BRANCH_NAME}"

- label: "@bugsnag/expo v48/next"
depends_on: "publish-js"
trigger: "bugsnag-expo"
build:
branch: "v48/next"
env:
BUGSNAG_JS_BRANCH: "${BUILDKITE_BRANCH}"
BUGSNAG_JS_COMMIT: "${BUILDKITE_COMMIT}"
# a branch name that's safe to use as a docker cache identifier
BUGSNAG_JS_CACHE_SAFE_BRANCH_NAME: "${BRANCH_NAME}"

- label: "@bugsnag/expo v47/next"
depends_on: "publish-js"
trigger: "bugsnag-expo"
build:
branch: "v47/next"
env:
BUGSNAG_JS_BRANCH: "${BUILDKITE_BRANCH}"
BUGSNAG_JS_COMMIT: "${BUILDKITE_COMMIT}"
# a branch name that's safe to use as a docker cache identifier
BUGSNAG_JS_CACHE_SAFE_BRANCH_NAME: "${BRANCH_NAME}"
Loading
Loading