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.
24 lines
679 B
TypeScript
24 lines
679 B
TypeScript
import { describe, expect, it } from 'vitest'
|
|
import { getClipboardPathForEntry } from '@/utils/file-path'
|
|
|
|
const baseEntry = {
|
|
name: 'app.log',
|
|
path: 'logs/app.log',
|
|
isDir: false,
|
|
size: 12,
|
|
modTime: '2026-05-20T00:00:00.000Z',
|
|
}
|
|
|
|
describe('file path clipboard helpers', () => {
|
|
it('prefers absolute path metadata when available', () => {
|
|
expect(getClipboardPathForEntry({
|
|
...baseEntry,
|
|
absolutePath: '/home/agent/.hermes/logs/app.log',
|
|
})).toBe('/home/agent/.hermes/logs/app.log')
|
|
})
|
|
|
|
it('falls back to the relative operation path for older API responses', () => {
|
|
expect(getClipboardPathForEntry(baseEntry)).toBe('logs/app.log')
|
|
})
|
|
})
|