-
-
Notifications
You must be signed in to change notification settings - Fork 106
47 lines (45 loc) · 1.5 KB
/
testing.yml
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
name: Testing
on: [push, pull_request]
jobs:
testing:
runs-on: macos-12
steps:
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
with:
ruby-version: '2.7'
bundler-cache: true
- name: Installing packages
run: |
brew update
brew install carthage swiftformat
brew install [email protected] || brew link --overwrite go
brew install swiftlint || brew link --overwrite swiftlint
gem install bundler
- uses: actions/cache@v3
id: carthage-cache
with:
path: Carthage
key: ${{ runner.os }}-carthage-${{ secrets.CACHE_VERSION }}-${{ hashFiles('**/Cartfile.resolved') }}
restore-keys: |
${{ runner.os }}-carthage-${{ secrets.CACHE_VERSION }}-
- uses: actions/cache@v3
id: gopenpgp-cache
with:
path: go
key: ${{ runner.os }}-gopenpgp-${{ secrets.CACHE_VERSION }}-${{ hashFiles('**/gopenpgp_build.sh') }}
restore-keys: |
${{ runner.os }}-gopenpgp-${{ secrets.CACHE_VERSION }}-
- name: Bundle Install
run: |
bundle config path vendor/bundle
bundle install --jobs 4 --retry 3
- name: Carthage
if: ${{ steps.carthage-cache.outputs.cache-hit == false }}
run: |
carthage bootstrap --no-use-binaries --cache-builds --use-xcframeworks
- name: GopenPGP
if: ${{ steps.gopenpgp-cache.outputs.cache-hit == false }}
run: ./scripts/gopenpgp_build.sh
- name: Testing
run: bundle exec fastlane test