Import the client, server, skills, tests, and build scripts as the starting point for the rebuild, then trim the surfaces this project does not ship: Electron desktop packaging, the marketing website, and the ESP32 firmware tree. CI keeps the web build, e2e, lockfile, release, and Docker workflows. Rename the package and CLI entry points to hermes-ui, drop the prepare hook so npm ci no longer triggers a build, and drop the removed tsconfig and nodemon references. Rewrite AGENTS.md, ARCHITECTURE.md, DEVELOPMENT.md, and the READMEs so the documented package map and hard rules match this repository. reference_code/ is ignored: it is a read-only snapshot, not an input to the build.
39 lines
1.3 KiB
TypeScript
39 lines
1.3 KiB
TypeScript
import { describe, expect, it } from 'vitest'
|
|
import { buildWorkflowSkillOptions, workflowAgentToSkillTarget } from '@/utils/hermes/workflow-skills'
|
|
|
|
describe('workflow skill helpers', () => {
|
|
it('maps workflow agents to skill API targets', () => {
|
|
expect(workflowAgentToSkillTarget('hermes')).toBe('hermes')
|
|
expect(workflowAgentToSkillTarget('claude-code')).toBe('claude')
|
|
expect(workflowAgentToSkillTarget('codex')).toBe('codex')
|
|
expect(workflowAgentToSkillTarget('unknown-agent')).toBe('hermes')
|
|
})
|
|
|
|
it('builds sorted enabled skill options without duplicate names', () => {
|
|
expect(buildWorkflowSkillOptions({
|
|
archived: [],
|
|
categories: [
|
|
{
|
|
name: 'beta',
|
|
description: '',
|
|
skills: [
|
|
{ name: 'write-report', description: '', enabled: true },
|
|
{ name: 'disabled-skill', description: '', enabled: false },
|
|
],
|
|
},
|
|
{
|
|
name: 'alpha',
|
|
description: '',
|
|
skills: [
|
|
{ name: 'analyze-data', description: '' },
|
|
{ name: 'write-report', description: '' },
|
|
],
|
|
},
|
|
],
|
|
})).toEqual([
|
|
{ label: 'analyze-data', value: 'analyze-data' },
|
|
{ label: 'write-report', value: 'write-report' },
|
|
])
|
|
})
|
|
})
|