file-test-bug
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseFile Test Bug
提交测试Bug
Creates a GitHub issue in for integration test failures.
microsoft/github-copilot-for-azure为集成测试失败在仓库创建GitHub Issue。
microsoft/github-copilot-for-azureInput
输入
- Skill name (required): e.g., ,
azure-role-selectorappinsights-instrumentation - Test run (optional): Timestamp of test run. Defaults to most recent with logs for the skill.
- 技能名称(必填):例如、
azure-role-selectorappinsights-instrumentation - 测试运行时间(可选):测试运行的时间戳。默认使用该技能最近带日志的测试运行记录。
Steps
步骤
- Ask user for skill name if not provided
- Parse for failures matching the skill
tests/reports/junit.xml - Find test run directory (specified or most recent with matching logs)
- Read from
agent-metadata.mdtests/reports/test-run-<timestamp>/<skillname>-<testname>/ - For each failure, read the actual line of code from the test file using the location (file:line) from junit.xml
- REQUIRED - Write diagnosis BEFORE creating issue:
- Analyze the agent-metadata.md to understand what the agent did
- Compare agent behavior to what the test expected (from the assertion)
- Identify the root cause (skill issue, test issue, or model behavior)
- Write 2-3 sentences per failed test explaining WHY it failed
- Suggest potential fixes (update skill, update test, or update fixtures)
- Create issue via :
github-mcp-server-create_issue
owner: microsoft
repo: github-copilot-for-azure
title: Integration test failure in <skill-name>
labels: ["bug", "integration-test"]
body: |
## Failed Tests
- <test-name>: <error message>
## Diagnosis
### Root Cause
<1-2 sentences explaining WHY the test failed based on agent-metadata.md analysis>
### Analysis per Test
- **<test-name>**: <what agent did vs what test expected>
### Suggested Fix
<one of: update skill, update test assertions, provide test fixtures>
## Details
### <test-name>
**Error:** <failure from junit.xml>
**Location:** <file:line>
```typescript
<actual line of code from the test file at the specified line number><full contents of agent-metadata.md file, verbatim>
</details>
```- 若未提供技能名称,询问用户获取
- 解析,查找与该技能匹配的失败用例
tests/reports/junit.xml - 找到测试运行目录(指定的目录或最近带匹配日志的目录)
- 从路径读取
tests/reports/test-run-<timestamp>/<skillname>-<testname>/文件agent-metadata.md - 针对每个失败用例,利用junit.xml中记录的位置(文件:行号)从测试文件中读取对应的代码行
- 必填 - 创建Issue前先撰写诊断内容:
- 分析agent-metadata.md文件,理解Agent的执行行为
- 对比Agent的实际行为与测试预期结果(来自断言信息)
- 确定根本原因(技能问题、测试问题或模型行为问题)
- 每个失败测试用例撰写2-3句话解释失败原因
- 提出潜在修复方案(更新技能、更新测试或更新测试夹具)
- 通过创建Issue:
github-mcp-server-create_issue
owner: microsoft
repo: github-copilot-for-azure
title: Integration test failure in <skill-name>
labels: ["bug", "integration-test"]
body: |
## Failed Tests
- <test-name>: <error message>
## Diagnosis
### Root Cause
<1-2 sentences explaining WHY the test failed based on agent-metadata.md analysis>
### Analysis per Test
- **<test-name>**: <what agent did vs what test expected>
### Suggested Fix
<one of: update skill, update test assertions, provide test fixtures>
## Details
### <test-name>
**Error:** <failure from junit.xml>
**Location:** <file:line>
```typescript
<actual line of code from the test file at the specified line number><full contents of agent-metadata.md file, verbatim>
</details>
```Important
重要说明
Include the complete, unmodified contents of each file in the issue body. Do NOT summarize or truncate the logs. Wrap each log in a block with the test name as the summary.
agent-metadata.md<details>在Issue正文中包含每个文件的完整、未修改内容。请勿总结或截断日志。将每个日志包裹在块中,以测试用例名称作为摘要。
agent-metadata.md<details>