# File Test Bug

> File a GitHub issue for local integration test failures. TRIGGERS: file test bug, report test failure, create bug for test, integration test failed, test failure issue, junit failure

- **Type:** Skill
- **Install:** `agentstack add skill-tyler-r-kendrick-agent-skills-file-test-bug`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [Tyler-R-Kendrick](https://agentstack.voostack.com/s/tyler-r-kendrick)
- **Installs:** 0
- **Category:** [Developer Tools](https://agentstack.voostack.com/c/developer-tools)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [Tyler-R-Kendrick](https://github.com/Tyler-R-Kendrick)
- **Source:** https://github.com/Tyler-R-Kendrick/agent-skills/tree/main/.agents/skills/file-test-bug

## Install

```sh
agentstack add skill-tyler-r-kendrick-agent-skills-file-test-bug
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# File Test Bug

Creates a GitHub issue in `microsoft/github-copilot-for-azure` for integration test failures.

## Input

- **Skill name** (required): e.g., `azure-role-selector`, `appinsights-instrumentation`
- **Test run** (optional): Timestamp of test run. Defaults to most recent with logs for the skill.

## Steps

1. Ask user for skill name if not provided
2. Parse `tests/reports/junit.xml` for failures matching the skill
3. Find test run directory (specified or most recent with matching logs)
4. Read `agent-metadata.md` from `tests/reports/test-run-/-/`
5. For each failure, read the actual line of code from the test file using the location (file:line) from junit.xml
6. **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)
7. Create issue via `github-mcp-server-create_issue`:

```
owner: microsoft
repo: github-copilot-for-azure
title: Integration test failure in 
labels: ["bug", "integration-test"]
body: |
  ## Failed Tests
  - : 
  
  ## Diagnosis
  
  ### Root Cause
  
  
  ### Analysis per Test
  - ****: 
  
  ### Suggested Fix
  

  ## Details
  ### 
  **Error:** 
  **Location:** 
  ```typescript
  
  ```
  
  
  agent-metadata.md
  
  
  
  
```

## Important

Include the **complete, unmodified contents** of each `agent-metadata.md` 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.

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [Tyler-R-Kendrick](https://github.com/Tyler-R-Kendrick)
- **Source:** [Tyler-R-Kendrick/agent-skills](https://github.com/Tyler-R-Kendrick/agent-skills)
- **License:** MIT

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-tyler-r-kendrick-agent-skills-file-test-bug
- Seller: https://agentstack.voostack.com/s/tyler-r-kendrick
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
