Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion tests/agents/validate-gdscript.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ function validateSnippet(code, file, blockIndex) {
}

function validateAgentFiles() {
const agentsDir = join(ROOT, '.opencode', 'agents');
const agentsDir = join(ROOT, '.agents', 'agents');
if (!existsSync(agentsDir)) {
console.log('No agents directory found');
process.exit(0);
Expand Down
8 changes: 4 additions & 4 deletions tests/modules/validate-modules.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ let passed = 0;
let failed = 0;

const PATH_MAP = {
agents: (name) => join(ROOT, ".opencode", "agents", `${name}.md`),
skills: (name) => join(ROOT, ".opencode", "skills", name, "SKILL.md"),
commands: (name) => join(ROOT, ".opencode", "commands", `${name}.md`),
rules: (name) => join(ROOT, ".opencode", "rules", `${name}.md`),
agents: (name) => join(ROOT, ".agents", "agents", `${name}.md`),
skills: (name) => join(ROOT, ".agents", "skills", name, "SKILL.md"),
commands: (name) => join(ROOT, ".agents", "commands", `${name}.md`),
rules: (name) => join(ROOT, ".agents", "rules", `${name}.md`),
};

function parseModulefile(filePath) {
Expand Down
10 changes: 5 additions & 5 deletions tests/workflow/gates.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { fileURLToPath } from 'url';
const __dirname = dirname(fileURLToPath(import.meta.url));
const ROOT = resolve(__dirname, '..', '..');

const SKILLS_DIR = join(ROOT, '.opencode', 'skills');
const SKILLS_DIR = join(ROOT, '.agents', 'skills');

function getSkillContent(name) {
const p = join(SKILLS_DIR, name, 'SKILL.md');
Expand Down Expand Up @@ -69,8 +69,8 @@ if (gate) {
'production/session-logs/',
'prototypes/explore/',
'design/difficulty-curve.md',
'.opencode/docs/technical-preferences.md',
'.opencode/docs/director-gates.md',
'docs/framework/technical-preferences.md',
'docs/framework/director-gates.md',
'.github/workflows/tests.yml',
'docs/consistency-failures.md',
]);
Expand Down Expand Up @@ -179,7 +179,7 @@ if (gate) {
const hybrid = readFileSync(hybridDoc, 'utf-8');
const refs = [...hybrid.matchAll(/`\/([a-z][\w-]+)`/g)].map(m => m[1]);
const unique = [...new Set(refs)];
const commandsDir = join(ROOT, '.opencode', 'commands');
const commandsDir = join(ROOT, '.agents', 'commands');
const commandNames = existsSync(commandsDir)
? new Set(readdirSync(commandsDir).filter(f => f.endsWith('.md') && f !== 'README.md').map(f => f.replace('.md', '')))
: new Set();
Expand Down Expand Up @@ -210,7 +210,7 @@ if (gate) {
const content = readFileSync(doc, 'utf-8');
const refs = [...content.matchAll(/`\/([a-z][\w-]+)`/g)].map(m => m[1]);
const unique = [...new Set(refs)];
const commandsDir = join(ROOT, '.opencode', 'commands');
const commandsDir = join(ROOT, '.agents', 'commands');
const commandNames = existsSync(commandsDir)
? new Set(readdirSync(commandsDir).filter(f => f.endsWith('.md') && f !== 'README.md').map(f => f.replace('.md', '')))
: new Set();
Expand Down
10 changes: 5 additions & 5 deletions tests/workflow/invariants.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import { fileURLToPath } from 'url';
const __dirname = dirname(fileURLToPath(import.meta.url));
const ROOT = resolve(__dirname, '..', '..');

const COMMANDS_DIR = join(ROOT, '.opencode', 'commands');
const SKILLS_DIR = join(ROOT, '.opencode', 'skills');
const AGENTS_DIR = join(ROOT, '.opencode', 'agents');
const COMMANDS_DIR = join(ROOT, '.agents', 'commands');
const SKILLS_DIR = join(ROOT, '.agents', 'skills');
const AGENTS_DIR = join(ROOT, '.agents', 'agents');
const DOCS_DIR = join(ROOT, 'docs');
const DESIGN_DIR = join(ROOT, 'design');
const PRODUCTION_DIR = join(ROOT, 'production');
Expand Down Expand Up @@ -144,10 +144,10 @@ console.log('\n=== Cross-Cutting Invariants ===\n');

{ // I4: No stale template placeholders in key config files
const configFiles = [
join(ROOT, '.opencode', 'docs', 'technical-preferences.md'),
join(ROOT, 'docs', 'framework', 'technical-preferences.md'),
];
const knownPlaceholderFiles = new Set([
join(ROOT, '.opencode', 'docs', 'technical-preferences.md'),
join(ROOT, 'docs', 'framework', 'technical-preferences.md'),
]);
const bad = [];
for (const file of configFiles) {
Expand Down
4 changes: 2 additions & 2 deletions tests/workflow/paths.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import { fileURLToPath } from 'url';
const __dirname = dirname(fileURLToPath(import.meta.url));
const ROOT = resolve(__dirname, '..', '..');

const SKILLS_DIR = join(ROOT, '.opencode', 'skills');
const COMMANDS_DIR = join(ROOT, '.opencode', 'commands');
const SKILLS_DIR = join(ROOT, '.agents', 'skills');
const COMMANDS_DIR = join(ROOT, '.agents', 'commands');
const DOCS_DIR = join(ROOT, 'docs');

function getSkillContent(name) {
Expand Down
6 changes: 3 additions & 3 deletions tests/workflow/references.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import { fileURLToPath } from 'url';
const __dirname = dirname(fileURLToPath(import.meta.url));
const ROOT = resolve(__dirname, '..', '..');

const COMMANDS_DIR = join(ROOT, '.opencode', 'commands');
const SKILLS_DIR = join(ROOT, '.opencode', 'skills');
const AGENTS_DIR = join(ROOT, '.opencode', 'agents');
const COMMANDS_DIR = join(ROOT, '.agents', 'commands');
const SKILLS_DIR = join(ROOT, '.agents', 'skills');
const AGENTS_DIR = join(ROOT, '.agents', 'agents');

function parseFrontmatter(content) {
const match = content.match(/^---\n([\s\S]*?)\n---/);
Expand Down