ci: fix red radioSpeech assertion and add a test/typecheck pipeline

The suite was red on main: the SID test still expected the old
letter-by-letter spelling ("Mike Alfa Romeo...") after the pronunciation
change to speak named waypoints as words ("Marun seven Foxtrot"). Update the
stale assertion.

Add a GitHub Actions workflow: yarn install + yarn test as the required gate,
plus a non-blocking vue-tsc job (TS strict mode is still off — promote to
required after that cleanup). Suite now 80/80.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
leubeem
2026-06-15 14:47:09 +02:00
parent 95b380f5e0
commit 9619bcbe40
2 changed files with 53 additions and 2 deletions

51
.github/workflows/ci.yml vendored Normal file
View File

@@ -0,0 +1,51 @@
name: CI
on:
push:
branches: [main]
pull_request:
jobs:
test:
name: Test suite
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Enable Corepack
run: corepack enable
- uses: actions/setup-node@v4
with:
node-version: 22
cache: yarn
- name: Install dependencies
run: yarn install --immutable
- name: Run tests
run: yarn test
typecheck:
name: Typecheck (non-blocking)
runs-on: ubuntu-latest
# TypeScript strict mode is currently disabled (see review QUAL-10). This job
# surfaces type errors without gating merges; promote it to a required check
# once the strict-mode cleanup lands.
continue-on-error: true
steps:
- uses: actions/checkout@v4
- name: Enable Corepack
run: corepack enable
- uses: actions/setup-node@v4
with:
node-version: 22
cache: yarn
- name: Install dependencies
run: yarn install --immutable
- name: vue-tsc
run: yarn vue-tsc --noEmit

View File

@@ -33,8 +33,8 @@ describe('radioSpeech', () => {
const sid = normalizeRadioPhrase('MARUN 7F')
const metar = normalizeMetarPhrase('EDDF 171450Z 28015G25KT 9999 -RA SCT025 BKN040 15/08 Q1013')
// SID prefix is spelled phonetically so TTS pronounces unfamiliar waypoint names correctly
assert.equal(sid, 'Mike Alfa Romeo Uniform November seven Foxtrot')
// SID identifier: the named waypoint is spoken as a word, the number and suffix letter are spelled out
assert.equal(sid, 'Marun seven Foxtrot')
assert.match(metar, /wind too eight zero degrees/)
assert.match(metar, /gusting too fife knots/)
assert.match(metar, /QNH wun zero wun tree/)