-
Notifications
You must be signed in to change notification settings - Fork 34
Expand file tree
/
Copy pathTaskfile.yml
More file actions
74 lines (67 loc) · 2.41 KB
/
Taskfile.yml
File metadata and controls
74 lines (67 loc) · 2.41 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
version: "3"
silent: true
tasks:
configure:
desc: Configure CMake with test support
cmds:
- cmd: cmake --preset macosx-universal -DBUILD_TESTING=ON
platforms: [darwin]
- cmd: cmake --preset win-x64 -DBUILD_TESTING=ON
platforms: [windows]
- cmd: cmake --preset linux-amd64 -DBUILD_TESTING=ON
platforms: [linux]
build:
desc: Build the test binary
deps: [configure]
cmds:
- cmd: >-
cmake --build build/macosx-universal
--target nakama-sdk-test
--config MinSizeRel
-- CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO CODE_SIGNING_ALLOWED=NO
platforms: [darwin]
- cmd: >-
cmake --build build/win-x64
--target nakama-sdk-test
--config MinSizeRel
platforms: [windows]
- cmd: >-
cmake --build build/linux-amd64
--target nakama-sdk-test
--config MinSizeRel
platforms: [linux]
server:up:
desc: Start the Nakama test server
cmds:
- docker compose -f integrationtests/server/docker-compose.yml up -d --build --wait
server:down:
desc: Stop the Nakama test server
cmds:
- docker compose -f integrationtests/server/docker-compose.yml down
server:logs:
desc: Tail Nakama server logs
cmds:
- docker compose -f integrationtests/server/docker-compose.yml logs -f nakama
test:
desc: Build and run integration tests (starts server automatically)
deps: [build]
cmds:
- docker compose -f integrationtests/server/docker-compose.yml up -d --build --wait
- cmd: cp build/win-x64/MinSizeRel/*.dll build/win-x64/integrationtests/MinSizeRel/ 2>/dev/null || true
platforms: [windows]
- cmd: build/macosx-universal/integrationtests/MinSizeRel/nakama-sdk-test.app/Contents/MacOS/nakama-sdk-test
platforms: [darwin]
- cmd: build/win-x64/integrationtests/MinSizeRel/nakama-sdk-test.exe
platforms: [windows]
- cmd: build/linux-amd64/integrationtests/MinSizeRel/nakama-sdk-test
platforms: [linux]
test-android:
desc: Build and run Android integration tests (optional DEVICE=<adb-serial>, ABI=arm64-v8a|armeabi-v7a)
env:
ABI: '{{.ABI}}'
CMAKE_PRESET: '{{.CMAKE_PRESET}}'
VCPKG_ROOT: '{{.VCPKG_ROOT}}'
ANDROID_NDK_HOME: '{{.ANDROID_NDK_HOME}}'
DEVICE: '{{.DEVICE}}'
cmds:
- bash integrationtests/android/test_android.sh