2019-09-20 19:41:31 +03:00
|
|
|
pr:
|
2022-07-22 22:07:45 +03:00
|
|
|
- main
|
2019-09-12 20:42:33 +03:00
|
|
|
|
2020-02-06 03:49:05 +03:00
|
|
|
variables:
|
2023-10-20 09:37:11 +03:00
|
|
|
- template: variables/vars.yml
|
2019-09-12 20:42:33 +03:00
|
|
|
|
2020-04-22 05:20:09 +03:00
|
|
|
jobs:
|
2023-04-23 07:18:40 +03:00
|
|
|
# Dedicated task to build JS code, including jest tests, snapshot testing, and linting, because these things can be super
|
2020-07-07 09:58:20 +03:00
|
|
|
# time consuming they don't need to run on every CI pass, instead do a dedicated JS loop to make the platform specific tests start quicker
|
2022-07-26 00:08:05 +03:00
|
|
|
- job: JSPR
|
|
|
|
displayName: JS PR
|
2020-05-20 02:28:41 +03:00
|
|
|
pool:
|
2020-07-30 01:26:39 +03:00
|
|
|
vmImage: 'ubuntu-latest'
|
2020-05-20 02:28:41 +03:00
|
|
|
timeoutInMinutes: 60 # how long to run the job before automatically cancelling
|
|
|
|
cancelTimeoutInMinutes: 5 # how much time to give 'run always even if cancelled tasks' before killing them
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- checkout: self
|
|
|
|
persistCredentials: true
|
|
|
|
|
2020-06-09 23:11:07 +03:00
|
|
|
- template: templates/setup-repo.yml
|
2020-05-20 02:28:41 +03:00
|
|
|
|
2020-07-07 09:58:20 +03:00
|
|
|
- script: |
|
2022-04-12 05:00:09 +03:00
|
|
|
yarn checkchange
|
|
|
|
displayName: 'check change'
|
2020-07-07 09:58:20 +03:00
|
|
|
|
2022-01-12 22:14:01 +03:00
|
|
|
- script: |
|
|
|
|
yarn prettier
|
|
|
|
displayName: 'check prettier'
|
|
|
|
|
2020-05-20 02:28:41 +03:00
|
|
|
- script: |
|
2022-04-12 05:00:09 +03:00
|
|
|
yarn buildci
|
2023-10-29 02:04:14 +03:00
|
|
|
displayName: 'yarn buildci [test]'
|
2020-05-20 02:28:41 +03:00
|
|
|
|
|
|
|
- script: |
|
|
|
|
yarn check-for-changed-files
|
2020-07-30 01:26:39 +03:00
|
|
|
displayName: 'verify API and Ensure Changed Files'
|
2020-05-20 02:28:41 +03:00
|
|
|
|
2022-07-26 00:08:05 +03:00
|
|
|
- job: AndroidPR
|
|
|
|
displayName: Android PR
|
2020-07-07 09:58:20 +03:00
|
|
|
pool:
|
2024-08-09 20:31:15 +03:00
|
|
|
vmImage: 'macos-latest'
|
2022-07-26 00:08:05 +03:00
|
|
|
variables:
|
|
|
|
platform: 'android'
|
2020-07-07 09:58:20 +03:00
|
|
|
timeoutInMinutes: 60 # how long to run the job before automatically cancelling
|
|
|
|
cancelTimeoutInMinutes: 5 # how much time to give 'run always even if cancelled tasks' before killing them
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- checkout: self
|
|
|
|
persistCredentials: true
|
|
|
|
|
2022-07-26 00:08:05 +03:00
|
|
|
# setup repo basics
|
2020-07-07 09:58:20 +03:00
|
|
|
- template: templates/setup-repo-min-build.yml
|
|
|
|
|
2022-07-26 00:08:05 +03:00
|
|
|
# package android bundle
|
|
|
|
- script: |
|
|
|
|
yarn bundle:$(platform)
|
|
|
|
workingDirectory: apps/fluent-tester
|
|
|
|
displayName: 'yarn bundle $(platform)'
|
2020-07-07 09:58:20 +03:00
|
|
|
|
2023-01-02 20:39:50 +03:00
|
|
|
# builds a debug apk and runs E2E tests on it
|
2024-10-18 09:15:57 +03:00
|
|
|
# Disable as Android E2E tests are failing
|
|
|
|
# - template: templates/e2e-testing-android.yml
|
2020-05-20 02:28:41 +03:00
|
|
|
|
2022-07-29 01:30:15 +03:00
|
|
|
- job: macOSPR
|
|
|
|
displayName: macOS PR
|
2020-04-22 05:20:09 +03:00
|
|
|
pool:
|
2023-10-20 09:37:11 +03:00
|
|
|
vmImage: $(VmImageApple)
|
2023-06-05 21:49:06 +03:00
|
|
|
variables:
|
|
|
|
platform: 'macos'
|
2020-04-22 05:20:09 +03:00
|
|
|
timeoutInMinutes: 60 # how long to run the job before automatically cancelling
|
|
|
|
cancelTimeoutInMinutes: 5 # how much time to give 'run always even if cancelled tasks' before killing them
|
2019-11-16 00:50:49 +03:00
|
|
|
|
2020-04-22 05:20:09 +03:00
|
|
|
steps:
|
2020-05-20 02:28:41 +03:00
|
|
|
- checkout: self
|
|
|
|
persistCredentials: true
|
|
|
|
|
2020-07-07 09:58:20 +03:00
|
|
|
- template: templates/setup-repo-min-build.yml
|
|
|
|
|
2024-05-23 00:30:06 +03:00
|
|
|
- template: templates/apple-tools-setup.yml
|
2024-02-15 21:56:34 +03:00
|
|
|
|
2020-07-07 09:58:20 +03:00
|
|
|
- script: |
|
2024-05-23 00:30:06 +03:00
|
|
|
set -eox pipefail
|
2022-07-29 01:30:15 +03:00
|
|
|
yarn bundle:macos
|
2022-07-26 00:08:05 +03:00
|
|
|
workingDirectory: apps/fluent-tester
|
2022-07-29 01:30:15 +03:00
|
|
|
displayName: 'yarn bundle macos'
|
2022-09-06 21:18:42 +03:00
|
|
|
|
2023-06-05 21:49:06 +03:00
|
|
|
- bash: |
|
2024-05-23 00:30:06 +03:00
|
|
|
set -eox pipefail
|
|
|
|
pod install --verbose
|
|
|
|
workingDirectory: apps/fluent-tester/macos
|
|
|
|
displayName: 'pod install'
|
|
|
|
|
|
|
|
- task: CmdLine@2
|
|
|
|
displayName: Build macOS
|
|
|
|
inputs:
|
|
|
|
script: |
|
|
|
|
set -eox pipefail
|
|
|
|
./.ado/scripts/xcodebuild.sh apps/fluent-tester/macos/FluentTester.xcworkspace macosx ReactTestApp build
|
|
|
|
env:
|
|
|
|
CCACHE_DISABLE: 1
|
2022-07-29 01:30:15 +03:00
|
|
|
|
|
|
|
- template: templates/e2e-testing-macos.yml
|
|
|
|
|
|
|
|
- job: iOSPR
|
|
|
|
displayName: iOS PR
|
|
|
|
pool:
|
2024-05-23 00:30:06 +03:00
|
|
|
vmImage: $(VmImageApple)
|
|
|
|
timeoutInMinutes: 60 # how long to run the job before automatically cancelling
|
2022-07-29 01:30:15 +03:00
|
|
|
cancelTimeoutInMinutes: 5 # how much time to give 'run always even if cancelled tasks' before killing them
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- checkout: self
|
|
|
|
persistCredentials: true
|
2020-05-20 02:28:41 +03:00
|
|
|
|
2022-07-29 01:30:15 +03:00
|
|
|
- template: templates/setup-repo-min-build.yml
|
|
|
|
|
2024-05-23 00:30:06 +03:00
|
|
|
- template: templates/apple-tools-setup.yml
|
2024-02-15 21:56:34 +03:00
|
|
|
|
2022-07-29 01:30:15 +03:00
|
|
|
- script: |
|
2024-05-23 00:30:06 +03:00
|
|
|
set -eox pipefail
|
2022-07-29 01:30:15 +03:00
|
|
|
yarn bundle:ios
|
|
|
|
workingDirectory: apps/fluent-tester
|
|
|
|
displayName: 'yarn bundle ios'
|
2022-09-06 21:18:42 +03:00
|
|
|
|
2023-06-05 21:49:06 +03:00
|
|
|
- bash: |
|
2024-05-23 00:30:06 +03:00
|
|
|
set -eox pipefail
|
|
|
|
pod install --verbose
|
|
|
|
workingDirectory: apps/fluent-tester/ios
|
|
|
|
displayName: 'pod install'
|
|
|
|
|
|
|
|
- task: CmdLine@2
|
|
|
|
displayName: Build iOS
|
|
|
|
inputs:
|
|
|
|
script: |
|
|
|
|
set -eox pipefail
|
|
|
|
./.ado/scripts/xcodebuild.sh apps/fluent-tester/ios/FluentTester.xcworkspace iphonesimulator ReactTestApp build
|
|
|
|
env:
|
|
|
|
CCACHE_DISABLE: 1
|
2021-02-18 19:06:20 +03:00
|
|
|
|
2024-04-04 00:34:07 +03:00
|
|
|
# Disable iOS E2E tests as they fail on macOS-13 images
|
|
|
|
# - template: templates/e2e-testing-ios.yml
|
2022-09-09 01:15:35 +03:00
|
|
|
|
2022-07-26 00:08:05 +03:00
|
|
|
# Windows bundling and end to end testing
|
|
|
|
- job: WindowsPR
|
|
|
|
displayName: Windows PR
|
2023-06-05 21:49:06 +03:00
|
|
|
pool:
|
|
|
|
name: rnw-pool-4
|
|
|
|
demands:
|
2024-04-11 20:32:42 +03:00
|
|
|
- ImageOverride -equals rnw-img-vs2022-node18
|
2021-02-18 19:06:20 +03:00
|
|
|
timeoutInMinutes: 60 # how long to run the job before automatically cancelling
|
|
|
|
cancelTimeoutInMinutes: 5 # how much time to give 'run always even if cancelled tasks' before killing them
|
|
|
|
|
2022-07-26 00:08:05 +03:00
|
|
|
# The "displayName" of all steps that execute a command within our repo (such as 'yarn build') start lowercase to make it
|
|
|
|
# easier to differentiate in-repo scripts from environmental setup. This makes it easier to understand CI pipeline results.
|
2021-02-18 19:06:20 +03:00
|
|
|
steps:
|
|
|
|
- checkout: self
|
|
|
|
persistCredentials: true
|
2022-12-06 04:36:45 +03:00
|
|
|
fetchDepth: 5
|
2021-02-18 19:06:20 +03:00
|
|
|
|
2022-07-26 00:08:05 +03:00
|
|
|
# yarn and minimal build to get set up
|
2021-02-18 19:06:20 +03:00
|
|
|
- template: templates/setup-repo-min-build.yml
|
|
|
|
|
2022-07-26 00:08:05 +03:00
|
|
|
# bundle windows adn do end to end tests
|
|
|
|
- template: templates/e2e-testing-uwp.yml
|
2021-02-18 19:06:20 +03:00
|
|
|
|
2022-07-26 00:08:05 +03:00
|
|
|
# Win32 bundling and end to end testing
|
|
|
|
- job: Win32PR
|
|
|
|
displayName: Win32 PR
|
|
|
|
pool:
|
|
|
|
vmImage: 'windows-2019'
|
|
|
|
timeoutInMinutes: 60
|
|
|
|
cancelTimeoutInMinutes: 5
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- checkout: self
|
|
|
|
persistCredentials: true
|
|
|
|
|
|
|
|
# yarn and minimal build to get set up
|
|
|
|
- template: templates/setup-repo-min-build.yml
|
2021-02-18 19:06:20 +03:00
|
|
|
|
2022-07-26 00:08:05 +03:00
|
|
|
# bundle win32 and do end to end tests
|
|
|
|
- template: templates/e2e-testing-win32.yml
|
2021-09-30 23:04:15 +03:00
|
|
|
|
|
|
|
# Dedicated task to make sure link on repo are functional.
|
|
|
|
- job: TestLinks
|
|
|
|
displayName: Test repo links
|
2022-03-01 00:51:57 +03:00
|
|
|
pool: cxe-ubuntu-20-04-small
|
2021-09-30 23:04:15 +03:00
|
|
|
timeoutInMinutes: 60 # how long to run the job before automatically cancelling
|
|
|
|
cancelTimeoutInMinutes: 5 # how much time to give 'run always even if cancelled tasks' before killing them
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- checkout: self
|
|
|
|
persistCredentials: true
|
|
|
|
|
|
|
|
- template: templates/setup-repo.yml
|
|
|
|
|
|
|
|
- script: |
|
|
|
|
find . -name \*.md -not -name CHANGELOG.md -not -path '*/\node_modules/*' -print0 | xargs -0 -n1 yarn test-links -c `pwd`/.ado/markdown-link-check-config.json
|
|
|
|
displayName: 'testing links'
|