@@ -11,13 +11,13 @@ concurrency:
11
11
cancel-in-progress : true
12
12
13
13
jobs :
14
- build :
15
- name : Build ${{ matrix.targetPlatform }} for AltTester 🛠️
16
- runs-on : ubuntu-latest-8-cores
17
- strategy :
18
- fail-fast : false
19
- matrix :
20
- include :
14
+ # build:
15
+ # name: Build ${{ matrix.targetPlatform }} for AltTester 🛠️
16
+ # runs-on: ubuntu-latest-8-cores
17
+ # strategy:
18
+ # fail-fast: false
19
+ # matrix:
20
+ # include:
21
21
# - targetPlatform: StandaloneOSX
22
22
# buildMethod: MacBuilder.BuildForAltTester
23
23
# buildPath: sample/Builds/MacOS
@@ -27,115 +27,112 @@ jobs:
27
27
# - targetPlatform: Android
28
28
# buildMethod: MobileBuilder.BuildForAltTester
29
29
# buildPath: sample/Builds/Android
30
- - targetPlatform : iOS
31
- buildMethod : MobileBuilder.BuildForAltTester
32
- buildPath : sample/Builds/iOS
33
- steps :
34
- - uses : actions/checkout@v3
35
- with :
36
- lfs : true
37
- - uses : actions/cache@v3
38
- with :
39
- path : Library
40
- key : Library-${{ matrix.targetPlatform }}-${{ hashFiles('sample/Assets/**', 'sample/Packages/**', 'sample/ProjectSettings/**') }}
41
- restore-keys : |
42
- Library-${{ matrix.targetPlatform }}
43
- Library-
44
- - name : Build project
45
- uses : game-ci/unity-builder@v4
46
- env :
47
- UNITY_EMAIL : ${{ secrets.UNITY_EMAIL }}
48
- UNITY_PASSWORD : ${{ secrets.UNITY_PASSWORD }}
49
- UNITY_SERIAL : ${{ secrets.UNITY_SERIAL }}
50
- with :
51
- targetPlatform : ${{ matrix.targetPlatform }}
52
- projectPath : sample
53
- buildMethod : ${{ matrix.buildMethod }}
54
- customParameters : -logFile logFile.log -quit -batchmode
55
- - name : List build directory
56
- run : ls -R ./
57
- - name : Upload artifact
58
- uses : actions/upload-artifact@v4
59
- if : always()
60
- with :
61
- name : Build-${{ matrix.targetPlatform }}
62
- path : ${{ matrix.buildPath }}
63
- test :
64
- name : Run ${{ matrix.targetPlatform }} UI tests 🧪
65
- needs : build
66
- strategy :
67
- matrix :
68
- include :
69
- # - targetPlatform: StandaloneOSX
70
- # runs-on: [self-hosted, macOS]
71
- # test_script: pytest -xs test/test_mac.py::MacTest
72
- # - targetPlatform: StandaloneWindows64
73
- # runs-on: [self-hosted, windows]
74
- # test_script: pytest -xs test/test_windows.py::WindowsTest
75
- # - targetPlatform: Android
76
- # runs-on: [ self-hosted, macOS ]
77
- # test_script: browserstack-sdk pytest -s ./test/test_android.py --browserstack.config "browserstack.android.yml"
78
- - targetPlatform : iOS
79
- runs-on : [ self-hosted, macOS ]
80
- test_script : browserstack-sdk pytest -s ./test/test_android.py --browserstack.config "browserstack.android.yml"
81
- concurrency :
82
- group : test-${{ matrix.targetPlatform }}
83
- runs-on : ${{ matrix.runs-on }}
84
- steps :
85
- - uses : actions/checkout@v3
86
- with :
87
- lfs : true
88
- - uses : actions/download-artifact@v4
89
- with :
90
- name : Build-${{ matrix.targetPlatform }}
91
- path : sample/Tests
92
- - name : Make macOS artifact executable
93
- if : ${{ matrix.targetPlatform == 'StandaloneOSX' }}
94
- run : chmod +x sample/Tests/SampleApp.app/Contents/MacOS/*
95
- - uses : actions/setup-python@v4
96
- with :
97
- python-version : " 3.10"
98
- - name : Install dependencies (Windows)
99
- if : ${{ matrix.targetPlatform == 'StandaloneWindows64' }}
100
- run : pip install -r "sample/Tests/requirements-desktop.txt"
101
- - name : Install dependencies (Mac)
102
- if : ${{ matrix.targetPlatform != 'StandaloneWindows64' }}
103
- run : |
104
- if [[ "${{ matrix.targetPlatform }}" == "StandaloneOSX" ]]; then
105
- pip uninstall -y browserstack-sdk || true
106
- pip install -r "sample/Tests/requirements-desktop.txt"
107
- else
108
- pip install -r "sample/Tests/requirements-mobile.txt"
109
- fi
110
- - name : Run UI tests
111
- env :
112
- UNITY_APP_PATH : SampleApp.app
113
- UNITY_APP_NAME : SampleApp
114
- MAILSLURP_API_KEY : ${{ secrets.MAILSLURP_API_KEY }}
115
- BROWSERSTACK_USERNAME : ${{ secrets.BROWSERSTACK_USERNAME }}
116
- BROWSERSTACK_ACCESS_KEY : ${{ secrets.BROWSERSTACK_ACCESS_KEY }}
117
- working-directory : sample/Tests
118
- run : ${{ matrix.test_script }}
119
- # test-ios:
120
- # name: Run iOS UI tests 🧪
121
- # runs-on: [ self-hosted, macOS ]
30
+ # steps:
31
+ # - uses: actions/checkout@v3
32
+ # with:
33
+ # lfs: true
34
+ # - uses: actions/cache@v3
35
+ # with:
36
+ # path: Library
37
+ # key: Library-${{ matrix.targetPlatform }}-${{ hashFiles('sample/Assets/**', 'sample/Packages/**', 'sample/ProjectSettings/**') }}
38
+ # restore-keys: |
39
+ # Library-${{ matrix.targetPlatform }}
40
+ # Library-
41
+ # - name: Build project
42
+ # uses: game-ci/unity-builder@v4
43
+ # env:
44
+ # UNITY_EMAIL: ${{ secrets.UNITY_EMAIL }}
45
+ # UNITY_PASSWORD: ${{ secrets.UNITY_PASSWORD }}
46
+ # UNITY_SERIAL: ${{ secrets.UNITY_SERIAL }}
47
+ # with:
48
+ # targetPlatform: ${{ matrix.targetPlatform }}
49
+ # projectPath: sample
50
+ # buildMethod: ${{ matrix.buildMethod }}
51
+ # customParameters: -logFile logFile.log -quit -batchmode
52
+ # - name: List build directory
53
+ # run: ls -R ./
54
+ # - name: Upload artifact
55
+ # uses: actions/upload-artifact@v4
56
+ # if: always()
57
+ # with:
58
+ # name: Build-${{ matrix.targetPlatform }}
59
+ # path: ${{ matrix.buildPath }}
60
+ # test:
61
+ # name: Run ${{ matrix.targetPlatform }} UI tests 🧪
62
+ # needs: build
63
+ # strategy:
64
+ # matrix:
65
+ # include:
66
+ # # - targetPlatform: StandaloneOSX
67
+ # # runs-on: [self-hosted, macOS]
68
+ # # test_script: pytest -xs test/test_mac.py::MacTest
69
+ # # - targetPlatform: StandaloneWindows64
70
+ # # runs-on: [self-hosted, windows]
71
+ # # test_script: pytest -xs test/test_windows.py::WindowsTest
72
+ # # - targetPlatform: Android
73
+ # # runs-on: [ self-hosted, macOS ]
74
+ # # test_script: browserstack-sdk pytest -s ./test/test_android.py --browserstack.config "browserstack.android.yml"
75
+ # - targetPlatform: iOS
76
+ # runs-on: [ self-hosted, macOS ]
77
+ # test_script: browserstack-sdk pytest -s ./test/test_android.py --browserstack.config "browserstack.android.yml"
78
+ # concurrency:
79
+ # group: test-${{ matrix.targetPlatform }}
80
+ # runs-on: ${{ matrix.runs-on }}
122
81
# steps:
123
82
# - uses: actions/checkout@v3
124
83
# with:
125
84
# lfs: true
126
- # - name: build iOS app
127
- # working-directory: sample
128
- # run: ./build_ios.sh
85
+ # - uses: actions/download-artifact@v4
86
+ # with:
87
+ # name: Build-${{ matrix.targetPlatform }}
88
+ # path: sample/Tests
89
+ # - name: Make macOS artifact executable
90
+ # if: ${{ matrix.targetPlatform == 'StandaloneOSX' }}
91
+ # run: chmod +x sample/Tests/SampleApp.app/Contents/MacOS/*
129
92
# - uses: actions/setup-python@v4
130
93
# with:
131
94
# python-version: "3.10"
132
- # - name: Install dependencies
133
- # run: pip install -r "sample/Tests/requirements.txt"
95
+ # - name: Install dependencies (Windows)
96
+ # if: ${{ matrix.targetPlatform == 'StandaloneWindows64' }}
97
+ # run: pip install -r "sample/Tests/requirements-desktop.txt"
98
+ # - name: Install dependencies (Mac)
99
+ # if: ${{ matrix.targetPlatform != 'StandaloneWindows64' }}
100
+ # run: |
101
+ # if [[ "${{ matrix.targetPlatform }}" == "StandaloneOSX" ]]; then
102
+ # pip uninstall -y browserstack-sdk || true
103
+ # pip install -r "sample/Tests/requirements-desktop.txt"
104
+ # else
105
+ # pip install -r "sample/Tests/requirements-mobile.txt"
106
+ # fi
134
107
# - name: Run UI tests
135
108
# env:
109
+ # UNITY_APP_PATH: SampleApp.app
110
+ # UNITY_APP_NAME: SampleApp
136
111
# MAILSLURP_API_KEY: ${{ secrets.MAILSLURP_API_KEY }}
137
112
# BROWSERSTACK_USERNAME: ${{ secrets.BROWSERSTACK_USERNAME }}
138
113
# BROWSERSTACK_ACCESS_KEY: ${{ secrets.BROWSERSTACK_ACCESS_KEY }}
139
114
# working-directory: sample/Tests
140
- # run: browserstack-sdk pytest -s ./test/test_ios.py --browserstack.config "browserstack.ios.yml"
115
+ # run: ${{ matrix.test_script }}
116
+ test-ios :
117
+ name : Run iOS UI tests 🧪
118
+ runs-on : [ self-hosted, macOS ]
119
+ steps :
120
+ - uses : actions/checkout@v3
121
+ with :
122
+ lfs : true
123
+ - name : build iOS app
124
+ working-directory : sample
125
+ run : ./build_ios.sh
126
+ - uses : actions/setup-python@v4
127
+ with :
128
+ python-version : " 3.10"
129
+ - name : Install dependencies
130
+ run : pip install -r "sample/Tests/requirements-mobile.txt"
131
+ - name : Run UI tests
132
+ env :
133
+ MAILSLURP_API_KEY : ${{ secrets.MAILSLURP_API_KEY }}
134
+ BROWSERSTACK_USERNAME : ${{ secrets.BROWSERSTACK_USERNAME }}
135
+ BROWSERSTACK_ACCESS_KEY : ${{ secrets.BROWSERSTACK_ACCESS_KEY }}
136
+ working-directory : sample/Tests
137
+ run : browserstack-sdk pytest -s ./test/test_ios.py --browserstack.config "browserstack.ios.yml"
141
138
0 commit comments