Skip to content
Merged
Changes from 1 commit
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
b32f101
feat: Stage 2a — CopilotIntegration with shared template primitives
mnriem Mar 31, 2026
ebb909f
feat: Stage 2b — --integration flag, routing, agent.json, shared infra
mnriem Mar 31, 2026
5cce80f
feat: Stage 2 completion — integration scripts, integration.json, sha…
mnriem Mar 31, 2026
b481c26
refactor: rename shared manifest to speckit.manifest.json
mnriem Mar 31, 2026
d9bfbdb
fix: copilot update-context scripts reflect target architecture
mnriem Mar 31, 2026
ce754a2
fix: simplify copilot scripts — dispatcher sources common functions
mnriem Mar 31, 2026
94e7d55
fix: copilot update-context scripts are self-contained implementations
mnriem Mar 31, 2026
be1c741
docs: add Stage 7 activation note to copilot update-context scripts
mnriem Mar 31, 2026
ccf0c81
test: add complete file inventory test for copilot integration
mnriem Mar 31, 2026
944aafd
test: add PowerShell file inventory test for copilot integration
mnriem Mar 31, 2026
d1842d5
refactor: split test_integrations.py into tests/integrations/ directory
mnriem Mar 31, 2026
28e85c4
refactor: move file inventory tests from test_cli to test_copilot
mnriem Mar 31, 2026
f4ea768
fix: skip JSONC merge to preserve user settings, fix docstring
mnriem Mar 31, 2026
b7d7e0e
fix: warn user when JSONC settings merge is skipped
mnriem Mar 31, 2026
fda1671
fix: show template content when JSONC merge is skipped
mnriem Mar 31, 2026
83752cf
fix: document process_template requirement, merge scripts without rmtree
mnriem Mar 31, 2026
bf1b679
fix: don't overwrite pre-existing shared scripts or templates
mnriem Mar 31, 2026
8c78da1
fix: warn user about skipped pre-existing shared files
mnriem Mar 31, 2026
93e371e
test: add test for shared infra skip behavior on pre-existing files
mnriem Mar 31, 2026
380aca5
fix: address review — containment check, deterministic prompts, manif…
mnriem Mar 31, 2026
8184244
fix: correct PS1 function names, document SPECKIT_SOURCE_ONLY prerequ…
mnriem Mar 31, 2026
02fd12b
fix: add dict type check for settings merge, simplify PS1 to subprocess
mnriem Mar 31, 2026
0ea0181
fix: skip-write on no-op merge, bash subprocess, dynamic integration …
mnriem Mar 31, 2026
7d38b0d
fix: align path rewriting with release script, add .specify/.specify/…
mnriem Mar 31, 2026
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
Prev Previous commit
Next Next commit
test: add complete file inventory test for copilot integration
Validates every single file (37 total) produced by
specify init --integration copilot --script sh --no-git.
  • Loading branch information
mnriem committed Mar 31, 2026
commit ccf0c81a1847203b3efb7710875c0361092bbc0a
82 changes: 82 additions & 0 deletions tests/test_integrations.py
Original file line number Diff line number Diff line change
Expand Up @@ -879,3 +879,85 @@ def test_ai_copilot_auto_promotes(self, tmp_path):
assert "--integration copilot" in result.output
# Should still produce copilot files via integration path
assert (project / ".github" / "agents" / "speckit.plan.agent.md").exists()

def test_complete_file_inventory(self, tmp_path):
"""Every file produced by --integration copilot is accounted for."""
from typer.testing import CliRunner
from specify_cli import app

project = tmp_path / "inventory-test"
project.mkdir()
import os
old_cwd = os.getcwd()
try:
os.chdir(project)
runner = CliRunner()
result = runner.invoke(app, [
"init", "--here",
"--integration", "copilot",
"--script", "sh",
"--no-git",
], catch_exceptions=False)
finally:
os.chdir(old_cwd)

assert result.exit_code == 0, f"init failed: {result.output}"

actual_files = sorted(
str(p.relative_to(project))
for p in project.rglob("*") if p.is_file()
)

expected_files = sorted([
# Copilot agent commands (9)
".github/agents/speckit.analyze.agent.md",
".github/agents/speckit.checklist.agent.md",
".github/agents/speckit.clarify.agent.md",
".github/agents/speckit.constitution.agent.md",
".github/agents/speckit.implement.agent.md",
".github/agents/speckit.plan.agent.md",
".github/agents/speckit.specify.agent.md",
".github/agents/speckit.tasks.agent.md",
".github/agents/speckit.taskstoissues.agent.md",
# Companion prompts (9)
".github/prompts/speckit.analyze.prompt.md",
".github/prompts/speckit.checklist.prompt.md",
".github/prompts/speckit.clarify.prompt.md",
".github/prompts/speckit.constitution.prompt.md",
".github/prompts/speckit.implement.prompt.md",
".github/prompts/speckit.plan.prompt.md",
".github/prompts/speckit.specify.prompt.md",
".github/prompts/speckit.tasks.prompt.md",
".github/prompts/speckit.taskstoissues.prompt.md",
# VS Code settings
".vscode/settings.json",
# Integration metadata
".specify/integration.json",
".specify/init-options.json",
".specify/integrations/copilot.manifest.json",
".specify/integrations/speckit.manifest.json",
# Integration-specific scripts
".specify/integrations/copilot/scripts/update-context.ps1",
".specify/integrations/copilot/scripts/update-context.sh",
# Shared scripts (bash)
".specify/scripts/bash/check-prerequisites.sh",
".specify/scripts/bash/common.sh",
".specify/scripts/bash/create-new-feature.sh",
".specify/scripts/bash/setup-plan.sh",
".specify/scripts/bash/update-agent-context.sh",
# Shared templates
".specify/templates/agent-file-template.md",
".specify/templates/checklist-template.md",
".specify/templates/constitution-template.md",
".specify/templates/plan-template.md",
".specify/templates/spec-template.md",
".specify/templates/tasks-template.md",
# Constitution (copied from template)
".specify/memory/constitution.md",
])

assert actual_files == expected_files, (
f"File inventory mismatch.\n"
f"Missing: {sorted(set(expected_files) - set(actual_files))}\n"
f"Extra: {sorted(set(actual_files) - set(expected_files))}"
)