Skip to content

Commit a6da0aa

Browse files
committed
Merge pull request #97742 from Repiteo/ci/godot-cpp-action
CI: Change `godot-cpp-test` from workflow to action
2 parents a7146ef + b8480ff commit a6da0aa

File tree

4 files changed

+49
-78
lines changed

4 files changed

+49
-78
lines changed
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Build godot-cpp
2+
description: Build godot-cpp with the provided options.
3+
4+
env:
5+
GODOT_CPP_BRANCH: 4.3
6+
7+
inputs:
8+
bin:
9+
description: Path to the Godot binary.
10+
required: true
11+
type: string
12+
scons-flags:
13+
description: Additional SCons flags.
14+
type: string
15+
scons-cache:
16+
description: The SCons cache path.
17+
default: ${{ github.workspace }}/.scons_cache/
18+
type: string
19+
20+
runs:
21+
using: composite
22+
steps:
23+
- name: Checkout
24+
uses: actions/checkout@v4
25+
with:
26+
submodules: recursive
27+
repository: godotengine/godot-cpp
28+
ref: ${{ env.GODOT_CPP_BRANCH }}
29+
path: godot-cpp
30+
31+
- name: Extract API
32+
shell: sh
33+
run: ${{ inputs.bin }} --headless --dump-gdextension-interface --dump-extension-api
34+
35+
- name: SCons Build
36+
shell: sh
37+
env:
38+
SCONS_CACHE: ${{ inputs.scons-cache }}
39+
run: scons --directory=./godot-cpp/test "gdextension_dir=${{ github.workspace }}" ${{ inputs.scons-flags }}

.github/workflows/godot_cpp_test.yml

Lines changed: 0 additions & 57 deletions
This file was deleted.

.github/workflows/linux_builds.yml

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,9 @@ jobs:
3333
proj-conv: true
3434
api-compat: true
3535
artifact: true
36-
cache-limit: 1
36+
# Validate godot-cpp compatibility on one arbitrary editor build.
37+
godot-cpp: true
38+
cache-limit: 2
3739

3840
- name: Editor with doubles and GCC sanitizers (target=editor, tests=yes, dev_build=yes, scu_build=yes, precision=double, use_asan=yes, use_ubsan=yes, linker=gold)
3941
cache-name: linux-editor-double-sanitizers
@@ -44,8 +46,6 @@ jobs:
4446
build-mono: false
4547
tests: true
4648
proj-test: true
47-
# Generate an API dump for godot-cpp tests.
48-
api-dump: true
4949
# Skip 2GiB artifact speeding up action.
5050
artifact: false
5151
cache-limit: 7
@@ -158,6 +158,13 @@ jobs:
158158
tests: ${{ matrix.tests }}
159159
scons-cache-limit: ${{ matrix.cache-limit }}
160160

161+
- name: Compilation (godot-cpp)
162+
uses: ./.github/actions/godot-cpp-build
163+
if: matrix.godot-cpp
164+
with:
165+
bin: ${{ matrix.bin }}
166+
scons-flags: target=template_debug dev_build=yes verbose=yes
167+
161168
- name: Save Godot build cache
162169
uses: ./.github/actions/godot-cache-save
163170
with:
@@ -187,12 +194,6 @@ jobs:
187194
with:
188195
name: ${{ matrix.cache-name }}
189196

190-
- name: Dump Godot API
191-
uses: ./.github/actions/godot-api-dump
192-
if: matrix.api-dump
193-
with:
194-
bin: ${{ matrix.bin }}
195-
196197
- name: Unit tests
197198
if: matrix.tests
198199
run: |

.github/workflows/runner.yml

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -44,15 +44,3 @@ jobs:
4444
name: 🌐 Web
4545
needs: static-checks
4646
uses: ./.github/workflows/web_builds.yml
47-
48-
# Third stage: Run auxiliary tests using build artifacts from previous jobs.
49-
50-
# Can be turned off for PRs that intentionally break compat with godot-cpp,
51-
# until both the upstream PR and the matching godot-cpp changes are merged.
52-
godot-cpp-test:
53-
name: 🪲 Godot CPP
54-
# This can be changed to depend on another platform, if we decide to use it for
55-
# godot-cpp instead. Make sure to move the .github/actions/godot-api-dump step
56-
# appropriately.
57-
needs: linux-build
58-
uses: ./.github/workflows/godot_cpp_test.yml

0 commit comments

Comments
 (0)