fix(ci): remove incomplete release tests (#2407)

This commit is contained in:
Neko
2026-08-30 03:11:51 +08:00
committed by GitHub
parent 2c1e223c8d
commit d8e62f12f0
3 changed files with 0 additions and 82 deletions
@@ -45,12 +45,4 @@ describe('normalizeActPayload', () => {
emotion: { name: 'happy', intensity: 1 },
})
})
it('normalizes an expression name from an ACT payload', () => {
expect(normalizeActPayload({
expression: ' smile ',
})).toEqual({
expression: 'smile',
})
})
})
@@ -241,54 +241,6 @@ describe('live2d zip loader settings sanitization', () => {
])
})
// ROOT CAUSE:
//
// Some valid Live2D archives contain expression and motion files that are
// absent from model3.json. The ZIP loader discovered these files for its
// report, but it did not add them to the runtime model settings. Pixi then
// omitted them from extraction and AIRI could not register them for ACT.
it('adds unreferenced expressions and motions to runtime model settings', async () => {
await import('./live2d-zip-loader')
const { ZipLoader } = await import('pixi-live2d-display/cubism4')
const settingsText = JSON.stringify({
Version: 3,
FileReferences: {
Moc: 'avatar.moc3',
Textures: ['textures/avatar.png'],
},
Groups: [],
})
const zip = new JSZip()
zip.file('avatar/avatar.model3.json', settingsText)
zip.file('avatar/avatar.moc3', new Uint8Array([77, 79, 67, 51]))
zip.file('avatar/textures/avatar.png', new Uint8Array([1, 2, 3]))
zip.file('avatar/expressions/smile.exp3.json', JSON.stringify({
Type: 'Live2D Expression',
Parameters: [{ Id: 'ParamMouthForm', Value: 1, Blend: 'Add' }],
}))
zip.file('avatar/motions/wave.motion3.json', JSON.stringify({ Version: 3, Curves: [] }))
const zipBytes = await zip.generateAsync({ type: 'uint8array' })
const reader = await JSZip.loadAsync(await blobFromBytes(zipBytes).arrayBuffer())
const settings = await ZipLoader.createSettings(reader)
const files = await ZipLoader.unzip(reader, settings)
expect(settings.expressions).toEqual([
{ Name: 'smile', File: 'expressions/smile.exp3.json' },
])
expect(settings.motions).toEqual({
AIRI: [{ File: 'motions/wave.motion3.json' }],
})
expect(files.map(file => file.webkitRelativePath).sort()).toEqual([
'avatar/avatar.moc3',
'avatar/expressions/smile.exp3.json',
'avatar/motions/wave.motion3.json',
'avatar/textures/avatar.png',
])
expect(await reader.file('avatar/avatar.model3.json')!.async('string')).toBe(settingsText)
})
it('loads an OPFS-restored file directory when model3.json contains Physics: null', async () => {
await import('./live2d-zip-loader')
const { FileLoader } = await import('pixi-live2d-display/cubism4')
@@ -1,6 +1,5 @@
import type { AiriCard } from './airi-card'
import { useLive2DActCapabilitiesStore } from '@proj-airi/stage-ui-live2d'
import { createPinia, setActivePinia } from 'pinia'
import { beforeEach, describe, expect, it, vi } from 'vitest'
@@ -504,31 +503,6 @@ describe('airi-card store', () => {
expect(cardStore.systemPrompt).not.toContain('What did you find?')
})
// ROOT CAUSE:
//
// The card prompt listed only AIRI's fixed emotion vocabulary. A loaded
// Live2D model could expose more expressions and motions, but the LLM did
// not receive their exact ACT identifiers.
it('adds current Live2D ACT capabilities to the system prompt', async () => {
const cardStore = useAiriCardStore()
const capabilities = useLive2DActCapabilitiesStore()
await cardStore.initialize()
capabilities.beginModel('display-model-iru-v2')
capabilities.setExpressions('display-model-iru-v2', [
{ name: 'smile', fileName: 'expressions/smile.exp3.json' },
])
capabilities.setMotions('display-model-iru-v2', [
{ fileName: 'motions/wave.motion3.json', group: 'AIRI', index: 0 },
])
expect(cardStore.systemPrompt).toContain('Live2D ACT controls for the current model:')
expect(cardStore.systemPrompt).toContain('- "smile"')
expect(cardStore.systemPrompt).toContain('- "motions/wave.motion3.json"')
expect(cardStore.systemPrompt).toContain('<|ACT {"expression":"smile"}|>')
expect(cardStore.systemPrompt).toContain('<|ACT {"motion":"motions/wave.motion3.json"}|>')
})
it('falls back to the default card when the active custom card is deleted', async () => {
const cardStore = useAiriCardStore()
await cardStore.initialize()