refactor(ci): generalize native smoke tests
Replace the feature-specific MP3 verification command with a workspace-wide native test entry point. Keep native regression cases in package-owned test suites so future checks can expand without adding workflow steps.
This commit is contained in:
6 files changed
+8
-7
No files matched your search
@@ -127,8 +127,8 @@ jobs:
|
||||
- name: Install dependencies
|
||||
run: pnpm install --frozen-lockfile
|
||||
|
||||
- name: Verify bundled record MP3 transcode
|
||||
run: pnpm --filter @snowluma/protocol test:native-audio
|
||||
- name: Run native smoke tests
|
||||
run: pnpm test:native
|
||||
|
||||
# Always builds the WebUI flavor — no separate "core-only" artifact.
|
||||
- name: Build project
|
||||
|
||||
@@ -45,8 +45,8 @@ jobs:
|
||||
- name: Install dependencies
|
||||
run: pnpm install --frozen-lockfile
|
||||
|
||||
- name: Verify bundled record MP3 transcode
|
||||
run: pnpm --filter @snowluma/protocol test:native-audio
|
||||
- name: Run native smoke tests
|
||||
run: pnpm test:native
|
||||
|
||||
# Always builds the WebUI flavor — no separate "core-only" artifact.
|
||||
- name: Build project
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
"test:watch": "pnpm --filter @snowluma/core test:watch",
|
||||
"test:common": "pnpm --filter @snowluma/common test",
|
||||
"test:all": "pnpm -r --if-present test",
|
||||
"test:native": "pnpm -r --if-present test:native",
|
||||
"coverage": "pnpm --filter @snowluma/common test -- --coverage",
|
||||
"typecheck": "pnpm -r --if-present typecheck",
|
||||
"lint": "eslint .",
|
||||
|
||||
@@ -91,7 +91,7 @@
|
||||
},
|
||||
"scripts": {
|
||||
"test": "vitest run",
|
||||
"test:native-audio": "vitest run tests/highway/audio-transcode-native.test.ts",
|
||||
"test:native": "vitest run tests/native",
|
||||
"bench": "vitest bench --run",
|
||||
"typecheck": "tsc --noEmit"
|
||||
},
|
||||
|
||||
@@ -6,7 +6,7 @@ import { AUDIO_OUT_FORMATS, convertAudioBytes, isAudioOutFormat } from '@snowlum
|
||||
|
||||
// convertAudioBytes is the pure (#165) transcode seam: write input → the
|
||||
// addon's dedicated audio transcoder → read output as base64 → always clean up
|
||||
// temp files. Unit tests inject a fake; audio-transcode-native.test.ts covers
|
||||
// temp files. Unit tests inject a fake; native/audio-transcode.test.ts covers
|
||||
// each bundled release-platform addon in the build matrices.
|
||||
|
||||
const tmpDir = mkdtempSync(path.join(os.tmpdir(), 'sl-audio-test-'));
|
||||
|
||||
+1
-1
@@ -61,7 +61,7 @@ const describeBundledAddon = isReleaseTarget
|
||||
? describe
|
||||
: describe.skip;
|
||||
|
||||
describeBundledAddon('bundled ffmpeg addon', () => {
|
||||
describeBundledAddon('bundled native ffmpeg addon', () => {
|
||||
let tmpDir: string;
|
||||
beforeAll(() => {
|
||||
tmpDir = mkdtempSync(path.join(os.tmpdir(), 'sl-native-audio-test-'));
|
||||
Reference in new issue
Block a user