From 428f8c378cf45d10f0dd9ff7848e644a962f4a7a Mon Sep 17 00:00:00 2001 From: Ivan Magda Date: Fri, 29 Sep 2023 11:51:24 +0400 Subject: [PATCH] GitHub Actions: iOS unit testing cron job (#686) --- .github/workflows/ios_unit_testing.yml | 40 ++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 .github/workflows/ios_unit_testing.yml diff --git a/.github/workflows/ios_unit_testing.yml b/.github/workflows/ios_unit_testing.yml new file mode 100644 index 0000000000..5f1ec8cbbf --- /dev/null +++ b/.github/workflows/ios_unit_testing.yml @@ -0,0 +1,40 @@ +name: iOS unit testing + +on: + workflow_dispatch: + # Runs at 00:00 UTC every day + schedule: + - cron: "0 0 * * *" + +concurrency: + group: ${{ github.workflow }} + cancel-in-progress: true + +defaults: + run: + shell: bash + +jobs: + unit-testing: + name: Run iOS unit tests + runs-on: macos-13 + timeout-minutes: 60 + + steps: + - name: Checkout + uses: actions/checkout@v4.1.0 + + - name: Setup CI + id: setup + uses: ./.github/actions/setup-ios + with: + git-crypt-key: ${{ secrets.GIT_CRYPT_KEY }} + + - name: Run unit tests + working-directory: './iosHyperskillApp' + run: bundle exec fastlane run_unit_tests install_pods:false + env: + FASTLANE_XCODEBUILD_SETTINGS_TIMEOUT: 60 + IS_GIT_CRYPT_UNLOCKED: ${{ steps.setup.outputs.is-git-crypt-unlocked }} + GITHUB_USER: ${{ github.actor }} + GITHUB_PERSONAL_ACCESS_TOKEN: ${{ secrets.GITHUB_TOKEN }}