-
-
Notifications
You must be signed in to change notification settings - Fork 17
135 lines (111 loc) · 3.61 KB
/
Copy pathci-react-native-iap.yml
File metadata and controls
135 lines (111 loc) · 3.61 KB
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
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
name: CI - react-native-iap
on:
pull_request:
branches: [main, next]
paths:
- "libraries/react-native-iap/**"
- "packages/gql/src/generated/types.ts"
- "packages/apple/Sources/**"
- "packages/apple/Package.swift"
- "openiap-versions.json"
- ".github/workflows/ci-react-native-iap.yml"
push:
branches: [main, next]
paths:
- "libraries/react-native-iap/**"
- "packages/gql/src/generated/types.ts"
- "packages/apple/Sources/**"
- "packages/apple/Package.swift"
- "openiap-versions.json"
- ".github/workflows/ci-react-native-iap.yml"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
defaults:
run:
working-directory: libraries/react-native-iap
jobs:
lint:
name: Lint
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v7
with:
fetch-depth: 1
- uses: actions/setup-node@v7
with:
node-version: 20
- name: Enable Corepack
run: corepack enable && corepack prepare yarn@3.6.1 --activate
- name: Cache Yarn
uses: actions/cache@v6
with:
path: libraries/react-native-iap/.yarn/cache
key: ${{ runner.os }}-yarn-${{ hashFiles('libraries/react-native-iap/yarn.lock') }}
restore-keys: ${{ runner.os }}-yarn-
- name: Install dependencies
run: yarn install --immutable
- name: Type check
run: yarn lint:tsc
test:
name: Test
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- uses: actions/checkout@v7
with:
fetch-depth: 1
- uses: actions/setup-node@v7
with:
node-version: 20
- name: Enable Corepack
run: corepack enable && corepack prepare yarn@3.6.1 --activate
- name: Cache Yarn
uses: actions/cache@v6
with:
path: libraries/react-native-iap/.yarn/cache
key: ${{ runner.os }}-yarn-${{ hashFiles('libraries/react-native-iap/yarn.lock') }}
restore-keys: ${{ runner.os }}-yarn-
- name: Install dependencies
run: yarn install --immutable
- name: Test
run: yarn test
- name: Consumer install smoke test
run: yarn verify:consumer-install
ios-xcode-27:
name: iOS example (Xcode 27)
if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name == github.repository
runs-on: xcode-27
timeout-minutes: 60
steps:
- uses: actions/checkout@v7
with:
fetch-depth: 1
persist-credentials: false
- uses: actions/setup-node@v7
with:
node-version: 20
- name: Enable Corepack
run: corepack enable && corepack prepare yarn@3.6.1 --activate
- name: Install dependencies
run: yarn install --immutable
- name: Generate Nitro bridge
run: yarn nitrogen
- name: Install Ruby dependencies
working-directory: libraries/react-native-iap/example
run: bundle install
- name: Install CocoaPods dependencies
working-directory: libraries/react-native-iap/example/ios
run: bundle exec pod install --repo-update
- name: Build scene-based iOS example
working-directory: libraries/react-native-iap/example/ios
run: |
set -o pipefail
xcodebuild build \
-workspace example.xcworkspace \
-scheme example \
-destination 'generic/platform=iOS Simulator' \
-configuration Debug \
CODE_SIGNING_ALLOWED=NO \
COMPILER_INDEX_STORE_ENABLE=NO