Skip to content

Bump the eslint group in /generators/react-native/templates with 2 updates #2995

Bump the eslint group in /generators/react-native/templates with 2 updates

Bump the eslint group in /generators/react-native/templates with 2 updates #2995

Workflow file for this run

name: iOS-E2E
on:
push:
branches:
- 'main'
pull_request:
defaults:
run:
shell: bash
concurrency:
# Group by workflow and ref, limit to 1 for pull requests
group: ${{ github.workflow }}-${{ github.ref }}-${{ startsWith(github.ref, 'refs/pull/') || github.run_number }}
# Cancel intermediate pull request builds
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
env:
SPRING_DOCKER_COMPOSE_ENABLED: false
jobs:
check-dependencies:
runs-on: ubuntu-latest
if: "!contains(github.event.head_commit.message, '[ci skip]') && !contains(github.event.head_commit.message, '[skip ci]') && !contains(github.event.pull_request.title, '[skip ci]') && !contains(github.event.pull_request.title, '[ci skip]') && !contains(github.event.ref_type, '[tag]')"
timeout-minutes: 5
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
- name: check-dependencies
run: |
cd generators/react-native/resources/expo
npm run check-dependencies
env:
EXPO_OFFLINE: 1
build-matrix:
runs-on: ubuntu-latest
needs: [check-dependencies]
outputs:
matrix: ${{ steps.build.outputs.matrix }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
cache: 'npm'
- id: build
run: |
npm ci --ignore-scripts --omit=dev
cli/cli.cjs github-build-matrix ios
applications:
name: ${{ matrix.sample }}
runs-on: ${{ matrix.os }}
needs: build-matrix
timeout-minutes: 90
defaults:
run:
working-directory: ${{ github.workspace }}/client
strategy:
fail-fast: false
matrix: ${{fromJson(needs.build-matrix.outputs.matrix)}}
env:
FORCE_COLOR: true
steps:
- uses: jhipster/actions/create-app-path@v0
with:
path: client
- uses: jhipster/actions/create-app-path@v0
with:
path: backend
- uses: jhipster/actions/setup-runner@v0
with:
node-version: ${{ matrix.node-version }}
java-version: ${{ matrix.java-version }}
maven-cache: true
binary-dir: ${{ github.workspace }}/generator-jhipster-react-native/cli
- uses: actions/checkout@v4
with:
path: generator-jhipster-react-native
fetch-depth: 2
- run: npm install
working-directory: ${{ github.workspace }}/generator-jhipster-react-native
- run: cli.cjs generate-sample ${{ matrix.sample }} --force --skip-commit-hook
working-directory: ${{ github.workspace }}/backend
- uses: jhipster/actions/compare-sample@v0
id: compare-backend
if: >-
github.event.pull_request &&
contains(github.event.pull_request.labels.*.name, 'pr: compare-backend')
with:
application-base-path: ${{ github.workspace }}/backend-base
application-folder: backend
compare-folder: backend
generator-path: generator-jhipster-react-native
cmd: cli.cjs generate-sample ${{ matrix.sample }} --force --skip-git --skip-commit-hook
- uses: jhipster/actions/compare-sample@v0
id: compare
if: >-
github.event.pull_request &&
!contains(github.event.pull_request.labels.*.name, 'pr: disable-compare') &&
steps.compare-backend.outputs.has-changes != 'true'
with:
application-folder: backend
compare-folder: client
generator-path: generator-jhipster-react-native
cmd: cli.cjs generate-sample ${{ matrix.sample }} --force --skip-git --skip-commit-hook
- uses: nick-invision/retry@v3.0.0
name: 'TOOLS: installing applesimutils'
if: steps.compare.outputs.equals != 'true'
with:
max_attempts: 3
timeout_minutes: 60
command: brew tap wix/brew && brew install applesimutils && applesimutils --list
retry_wait_seconds: 15
- uses: douglascamata/setup-docker-macos-action@8d5fa43892aed7eee4effcdea113fd53e4d4bf83
if: matrix.default-environment == 'prod' && steps.compare.outputs.equals != 'true'
timeout-minutes: 10
- run: npm run services:up
if: matrix.default-environment == 'prod' && steps.compare.outputs.equals != 'true'
working-directory: ${{ github.workspace }}/backend
- run: npm install
if: steps.compare.outputs.equals != 'true'
- run: npx expo prebuild -p ios
if: steps.compare.outputs.equals != 'true'
- run: npm run e2e:build:ios
if: steps.compare.outputs.equals != 'true'
- run: |
npm run app:start &
npm install -g wait-on
wait-on -t 60000 http-get://127.0.0.1:8080/management/health
if: steps.compare.outputs.equals != 'true' && matrix.skip-e2e != 'true'
working-directory: ${{ github.workspace }}/backend
- run: npm run e2e:test:ios
timeout-minutes: 15
env:
DETOX_RECORD_VIDEOS: "${{ contains(github.event.pull_request.labels.*.name, 'pr: record-videos') && 'all' || 'none' }}"
if: steps.compare.outputs.equals != 'true' && matrix.skip-e2e != 'true'
- uses: actions/upload-artifact@v4
if: steps.compare.outputs.equals != 'true' && always()
with:
name: expo-app-${{ matrix.sample }}
path: |
${{ github.workspace }}/client/
!${{ github.workspace }}/**/android
!${{ github.workspace }}/**/ios
!${{ github.workspace }}/**/node_modules
ios-result:
permissions:
contents: none
runs-on: ubuntu-latest
needs: [applications]
if: always()
steps:
- run: |
echo '${{ toJSON(needs) }}'
if ([ 'skipped' == '${{ needs.applications.result }}' ] || [ 'success' == '${{ needs.applications.result }}' ]); then
exit 0
fi
if [ 'closed' == '${{ github.event.action }}' ]; then
exit 0
fi
exit 1