Reuse the Windows print gate cache for the exact app acceptance

This commit is contained in:
Codex committed 2026-12-03 00:50:46 +01:00
1 parent 987c5535ef
commit 2d49ea5c4e
1 file changed
+20 -34
@@ -13,40 +13,26 @@ concurrency:
jobs:
native-vectorcraft:
runs-on: windows-2022
timeout-minutes: 145
env:
CARGO_PROFILE_DEV_DEBUG: "0"
CARGO_PROFILE_TEST_DEBUG: "0"
CARGO_INCREMENTAL: "0"
CARGO_BUILD_JOBS: "2"
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1
with:
persist-credentials: false
- name: Test the actual app against the shared Windows candidate
shell: pwsh
run: |
$ErrorActionPreference = 'Stop'
$PSNativeCommandUseErrorActionPreference = $true
rustup default stable
$previous = '77ade517ecb2a6ad86feb2f9983a098ad5738fc6'
$candidate = 'da3876b447adbf0918d7a49c095cd37b3df0bba0'
foreach ($manifest in @('Cargo.toml', 'apps/vectorcraft-web/Cargo.toml')) {
$path = Join-Path $PWD $manifest
$text = [IO.File]::ReadAllText($path)
[IO.File]::WriteAllText($path, $text.Replace($previous, $candidate))
}
$log = Join-Path $env:RUNNER_TEMP 'dialog-tests.log'
cargo test -p vectorcraft -p vectorcraft-ui-egui --lib dialogs::tests_print 2>&1 | Tee-Object -FilePath $log
if (-not (Select-String -Quiet -Path $log -SimpleMatch 'properties_are_kept_for_the_exact_job_and_a_refusal_sends_nothing ... ok')) {
throw 'The expected VectorCraft Properties dialog test did not pass'
}
$log = Join-Path $env:RUNNER_TEMP 'spooler-tests.log'
cargo test -p vectorcraft -p vectorcraft-ui-egui --bin vectorcraft printing:: 2>&1 | Tee-Object -FilePath $log
if (-not (Select-String -Quiet -Path $log -SimpleMatch 'exact_queue_uses_opaque_properties_without_repeating_composed_copies ... ok')) {
throw 'The VectorCraft Windows spooler adapter test did not pass'
}
uses: storytold/craft-common-actions/.github/workflows/gate.yml@main
with:
os: '["windows-2022"]'
timeout-minutes: 145
dev-strip: true
dev-debug: "0"
craft-fonts-ref: ""
tools: ""
targets: ""
command: |
set -euo pipefail
previous=77ade517ecb2a6ad86feb2f9983a098ad5738fc6
candidate=da3876b447adbf0918d7a49c095cd37b3df0bba0
sed -i "s/$previous/$candidate/g" Cargo.toml apps/vectorcraft-web/Cargo.toml
log="$RUNNER_TEMP/dialog-tests.log"
cargo test -p vectorcraft -p vectorcraft-ui-egui --lib dialogs::tests_print 2>&1 | tee "$log"
grep -F 'properties_are_kept_for_the_exact_job_and_a_refusal_sends_nothing ... ok' "$log"
log="$RUNNER_TEMP/spooler-tests.log"
cargo test -p vectorcraft -p vectorcraft-ui-egui --bin vectorcraft printing:: 2>&1 | tee "$log"
grep -F 'exact_queue_uses_opaque_properties_without_repeating_composed_copies ... ok' "$log"
shared-action:
runs-on: ubuntu-24.04