Files
makelore/tests/unit/game-engine-skill.test.ts
inman 26b52d76e3
Some checks failed
Electron E2E / Electron E2E (macos-latest) (push) Has been cancelled
Electron E2E / Electron E2E (ubuntu-latest) (push) Has been cancelled
Electron E2E / Electron E2E (windows-latest) (push) Has been cancelled
feat: 完善图像工作区与创作工具体验
2026-08-16 14:08:27 +08:00

18 lines
935 B
TypeScript

import { readFile } from 'node:fs/promises';
import path from 'node:path';
import { describe, expect, it } from 'vitest';
const skillRoot = path.join(process.cwd(), '.opencode', 'skills', 'game-engine');
describe('bundled game-engine Skill', () => {
it('keeps the upstream guidance, Makelore boundaries, templates, references, and license', async () => {
const skill = await readFile(path.join(skillRoot, 'SKILL.md'), 'utf8');
expect(skill).toContain('name: game-engine');
expect(skill).toContain('## Makelore 使用边界');
await expect(readFile(path.join(skillRoot, 'LICENSE'), 'utf8')).resolves.toContain('MIT License');
await expect(readFile(path.join(skillRoot, 'assets', '2d-platform-game.md'), 'utf8')).resolves.toContain('2D Platform Game Template');
await expect(readFile(path.join(skillRoot, 'references', 'game-engine-core-principles.md'), 'utf8')).resolves.toContain('game engine');
});
});