-
Notifications
You must be signed in to change notification settings - Fork 1
65 lines (58 loc) · 2.12 KB
/
qa-tests.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
name: QA Tests
on:
push:
branches:
- main
pull_request:
workflow_dispatch:
schedule:
- cron: '0 12 * * *' # Run every day at 7/8 AM Eastern
env:
DEVELOPER_DIR: '/Applications/Xcode_14.3.1.app/Contents/Developer'
jobs:
CI:
runs-on: macos-13
env:
# Avoid concurrency issues
BROWSERSTACK_CUSTOM_ID: ${{ (github.event_name == 'pull_request' || github.event_name == 'workflow_dispatch') && format('pr-{0}', github.sha) || 'iOSApp' }}
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Set up env
run: |
cd Sample/
brew install xcodesorg/made/xcodes
bundle install
- name: Install the Apple certificate and provisioning profile and build app
env:
MATCH_KEY_ID: ${{ secrets.MATCH_KEY_ID }}
MATCH_ISSUER_ID: ${{ secrets.MATCH_ISSUER_ID }}
MATCH_P8: ${{ secrets.MATCH_P8 }}
MATCH_PASSWORD: ${{ secrets.MATCH_PASSWORD }}
MATCH_GIT_PRIVATE_KEY: ${{ secrets.MATCH_GIT_PRIVATE_KEY }}
BROWSERSTACK_USERNAME: ${{ secrets.BROWSERSTACK_USERNAME }}
BROWSERSTACK_ACCESS_KEY: ${{ secrets.BROWSERSTACK_ACCESS_KEY }}
BROWSERSTACK_CUSTOM_ID: ${{ env.BROWSERSTACK_CUSTOM_ID }}
run: |
cd Sample/
bundle exec fastlane build_ci_app
- name: Checkout Integration Test Repo
uses: actions/checkout@v3
with:
repository: teamforage/mobile-qa-tests
ref: main
ssh-key: ${{ secrets.MOBILE_QA_DEPLOY_KEY }}
path: 'mobile-qa-tests/'
- name: Set up Python 3.12
uses: actions/setup-python@v4
with:
python-version: '3.12'
- name: Run Integration Tests
env:
BROWSERSTACK_CUSTOM_ID: ${{ env.BROWSERSTACK_CUSTOM_ID }}
run: |
cd mobile-qa-tests
pip3 install -r requirements.txt
export BROWSERSTACK_CUSTOM_ID=${{ env.BROWSERSTACK_CUSTOM_ID }}
pytest ios/tests/test_basic_flow.py || true
pytest --lf --last-failed-no-failures none --suppress-no-test-exit-code ios/tests/test_basic_flow.py