-
Notifications
You must be signed in to change notification settings - Fork 7
53 lines (51 loc) · 1.6 KB
/
check.yml
File metadata and controls
53 lines (51 loc) · 1.6 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
on:
push:
branches:
- main
pull_request:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: lts/jod
- run: npm ci
- run: npm run lint
test-simple:
name: Run tests which doesn't require MacOS
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: lts/jod
- run: npm ci
- run: npm run build
- run: npm test --workspace gyp-to-cmake --workspace react-native-node-api-cmake --workspace react-native-node-api-modules
test-macos:
name: Run tests which requires MacOS
runs-on: macos-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: lts/jod
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: "17"
distribution: "temurin"
- name: Setup Android SDK
uses: android-actions/setup-android@v3
# Version here should match the one in React Native template and packages/react-native-node-api-cmake/src/cli.ts
- run: sdkmanager --install "ndk;27.1.12297006"
- run: npm ci
- run: npm run build
- run: npm run copy-node-api-headers --workspace react-native-node-api-modules
- run: npm run build-weak-node-api --workspace react-native-node-api-modules
- run: npm test --workspace react-native-node-addon-examples