用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/Bradliebs/ollama-agent-harness --skill testing命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
Systematic debugging for the Ollama Agent Harness — reproduce, localize, reduce, fix, guard
Git workflow for the Ollama Agent Harness — atomic commits, small changes, safe history
Security hardening for the Ollama Agent Harness — input validation, command injection, secrets, deny-first review
基于 SOC 职业分类
正在显示 SKILL.md
| name | testing |
| description | Testing conventions for the Ollama Agent Harness using Jest |
| domain | testing |
| confidence | medium |
| source | generated by CopilotForge |
| triggers | ["write tests","test this","add test coverage"] |
Testing skill for the Ollama Agent Harness. Uses Jest with TypeScript. Tests cover the core subsystems: agent loop, tool dispatch, permission evaluation, context management, subagent delegation, and session persistence.
src/core/queryLoop.test.tstests/integration/tests/fixtures/Mock the Ollama client to return controlled responses. Test the loop's behavior with:
Test deny-first rule ordering:
const mockOllama = {
chat: jest.fn().mockResolvedValue({
message: { role: 'assistant', content: 'Done', tool_calls: [] },
done: true,
}),
};
it('denies tool when deny rule matches before allow rule')toEqual for object comparison, toBe for primitivesdescribe('queryLoop', () => {
it('stops when model returns text-only response', async () => {
mockOllama.chat.mockResolvedValueOnce({
message: { role: 'assistant', content: 'All done.' },
done: true,
});
const events = [];
for await (const event of queryLoop(config)) {
events.push(event);
}
expect(events).toHaveLength(1);
expect(events[0].type).toBe('text');
});
});
describe('permissions', () => {
it('deny rule overrides specific allow rule', () => {
const rules = [
{ type: 'allow', tool: 'bash', pattern: 'npm test' },
{ type: 'deny', tool: 'bash' },
];
const result = evaluate(rules, { tool: 'bash', input: 'npm test' });
expect(result.decision).toBe('deny');
});
});