CI: Add redot-cpp testing action

This commit is contained in:
Spartan322
2025-03-07 19:00:32 -05:00
parent f178ebc70f
commit 6c9e69b5bf
2 changed files with 48 additions and 0 deletions

View File

@@ -0,0 +1,39 @@
name: Build redot-cpp
description: Build redot-cpp with the provided options.
env:
REDOT_CPP_BRANCH: 4.3
inputs:
bin:
description: Path to the Redot binary.
required: true
type: string
scons-flags:
description: Additional SCons flags.
type: string
scons-cache:
description: The SCons cache path.
default: ${{ github.workspace }}/.scons_cache/
type: string
runs:
using: composite
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: recursive
repository: Redot-Engine/redot-cpp
ref: ${{ env.REDOT_CPP_BRANCH }}
path: redot-cpp
- name: Extract API
shell: sh
run: ${{ inputs.bin }} --headless --dump-gdextension-interface --dump-extension-api
- name: SCons Build
shell: sh
env:
SCONS_CACHE: ${{ inputs.scons-cache }}
run: scons --directory=./redot-cpp/test "gdextension_dir=${{ github.workspace }}" ${{ inputs.scons-flags }}

View File

@@ -35,6 +35,8 @@ jobs:
artifact: true
# Validate godot-cpp compatibility on one arbitrary editor build.
godot-cpp: true
# Validate redot-cpp compatibility on one arbitrary editor build.
redot-cpp: true
cache-limit: 2
- 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)
@@ -175,6 +177,13 @@ jobs:
bin: ${{ matrix.bin }}
scons-flags: target=template_debug dev_build=yes verbose=yes
- name: Compilation (redot-cpp)
uses: ./.github/actions/redot-cpp-build
if: matrix.redot-cpp
with:
bin: ${{ matrix.bin }}
scons-flags: target=template_debug dev_build=yes verbose=yes
- name: Save Godot build cache
uses: ./.github/actions/godot-cache-save
with: