From b0e7bd2fd2498a33f8c9d7583229c7b1cb2bd2b0 Mon Sep 17 00:00:00 2001 From: Ray Kao Date: Thu, 29 Jan 2026 23:36:50 -0500 Subject: [PATCH 1/5] feat(prompts): for analyzing commits and creating documentation and test coverage issues - Added from https://github.com/sitoader/AgenticWorkflows --- .github/prompts/analyze-for-docs.prompt.md | 43 +++++++ .github/prompts/analyze-for-tests.prompt.md | 126 ++++++++++++++++++++ 2 files changed, 169 insertions(+) create mode 100644 .github/prompts/analyze-for-docs.prompt.md create mode 100644 .github/prompts/analyze-for-tests.prompt.md diff --git a/.github/prompts/analyze-for-docs.prompt.md b/.github/prompts/analyze-for-docs.prompt.md new file mode 100644 index 0000000..a165e33 --- /dev/null +++ b/.github/prompts/analyze-for-docs.prompt.md @@ -0,0 +1,43 @@ +# Analyze Commit and Create Documentation Issue + +Analyze commit `{COMMIT_SHA}` in repository `{REPOSITORY}` using the GitHub MCP server. + +## Your Task + +1. **Examine the commit** using MCP to access: + - Commit diff and changed files + - Current documentation structure + - Project context + +2. **Decide if documentation is needed** based on these criteria: + + ### โœ… Document These: + - Public APIs/Interfaces (functions, classes, endpoints) + - Complex logic requiring explanation + - Architectural or workflow changes + - Breaking changes + - New dependencies or integrations + - Security/performance changes + - Database schemas or data models + - Unit tests + + ### โŒ Skip These: + - Minor refactoring or formatting + - Internal helpers + - Trivial typo fixes + - Code moves without logic changes + - Patch dependency updates +in the current repository + - Add labels: `documentation`, `automated` +3. **If documentation is needed:** + - Use the GitHub MCP server to create a GitHub issue with title: "๐Ÿ“š Documentation needed for commit test" + - Use assign_copilot_to_issue tool to assign @copilot to issue. + - In the issue body, explain: + - What changed and why it needs documentation + - Which documentation files should be updated + - Any breaking changes or migration notes needed + - Confirm if all steps succeeded or not. + +4. **If documentation is NOT needed:** + - Simply explain why in a brief response (no issue needed) + diff --git a/.github/prompts/analyze-for-tests.prompt.md b/.github/prompts/analyze-for-tests.prompt.md new file mode 100644 index 0000000..8528cfc --- /dev/null +++ b/.github/prompts/analyze-for-tests.prompt.md @@ -0,0 +1,126 @@ +# Analyze Commit for Unit Test Coverage + +Analyze commit `{COMMIT_SHA}` in repository `{REPOSITORY}` using the GitHub MCP server to determine if unit tests are missing or need to be added. + +## Your Task + +1. **Examine the commit** using MCP to access: + - Commit diff and all changed files + - Existing test files in the repository + - Project structure and testing patterns + +2. **Identify testable code changes** - Look for: + - New functions, methods, or classes + - Modified business logic + - New API endpoints or routes + - Data validation or transformation logic + - Error handling paths + - Edge cases in algorithms + +3. **Check for corresponding tests** using these language-agnostic patterns: + + ### Common Test File Patterns: + | Source File | Expected Test File Patterns | + |-------------|----------------------------| + | `src/foo.ts` | `src/foo.test.ts`, `src/foo.spec.ts`, `test/foo.test.ts`, `tests/foo.test.ts` | + | `src/foo.py` | `src/test_foo.py`, `tests/test_foo.py`, `src/foo_test.py` | + | `src/Foo.java` | `src/FooTest.java`, `test/FooTest.java` | + | `src/foo.go` | `src/foo_test.go` | + | `src/foo.rs` | `src/foo_test.rs`, `tests/foo.rs` | + | `src/foo.rb` | `spec/foo_spec.rb`, `test/foo_test.rb` | + | `src/foo.cs` | `src/FooTests.cs`, `tests/FooTests.cs` | + | `lib/foo.js` | `lib/foo.test.js`, `test/foo.test.js` | + + ### Common Test Directories: + - `test/`, `tests/`, `spec/`, `__tests__/` + - `src/__tests__/`, `src/test/` + - Language-specific: `pytest/`, `jest/`, `rspec/` + +4. **Evaluate test coverage need** based on: + + ### โœ… Tests Likely Needed: + - New public functions/methods without corresponding test additions + - Complex conditional logic (if/else, switch) added + - New error handling or exception paths + - Data parsing, validation, or transformation + - New API endpoints or route handlers + - Database queries or data access logic + - Security-related code (auth, encryption, sanitization) + - Business rules or domain logic + - Integration points with external services + + ### โŒ Tests Likely NOT Needed: + - Pure configuration file changes + - Documentation or comment-only changes + - Type definitions or interfaces only + - Simple constant definitions + - Dependency version updates only + - CSS/styling changes only + - Trivial getter/setter additions + - Test file changes themselves (tests testing tests) + - Generated or auto-generated code + - Migration scripts that are run once + +5. **Calculate a confidence score** (0-100) for whether tests are needed: + - 80-100: Tests definitely needed - significant untested logic added + - 60-79: Tests recommended - meaningful code without test coverage + - 40-59: Tests optional - minor changes that could use tests + - 0-39: Tests not needed - trivial or already covered + +6. **If tests are recommended (score >= 60):** + + Create a GitHub issue using MCP with: + + **Title:** `๐Ÿงช Unit tests needed for: [brief description of changes]` + + **Body should include:** + ```markdown + ## Test Coverage Analysis + + **Commit:** {COMMIT_SHA} + **Confidence Score:** [X]/100 + + ### Files Needing Tests + + | Source File | Status | Suggested Test File | + |-------------|--------|---------------------| + | `path/to/file.ext` | โš ๏ธ No tests found | `path/to/file.test.ext` | + + ### Recommended Test Cases + + For each file, list specific functions/methods and suggested test scenarios: + + #### `filename.ext` + - [ ] Test `functionName()` - happy path + - [ ] Test `functionName()` - error handling + - [ ] Test `functionName()` - edge cases (null, empty, boundary values) + + ### Why Tests Are Needed + + [Explain the risk of not having tests for this code] + + ### Testing Hints + + - Framework detected: [Jest/Pytest/JUnit/etc. or "Unknown"] + - Existing test patterns: [Describe patterns found in repo] + - Mock/stub suggestions: [If external dependencies need mocking] + + --- + *Auto-generated by test coverage workflow* + ``` + + - Add labels: `testing`, `automated`, `unit-tests` + - Use assign_copilot_to_issue tool to assign @copilot to the issue + +7. **If tests are NOT needed (score < 60):** + - Provide a brief explanation of why tests aren't necessary + - No issue creation needed + +## Important Guidelines + +- Be language-agnostic - detect the language from file extensions +- Consider the project's existing testing conventions +- Don't flag test files as needing tests +- Consider that some projects use different testing philosophies +- Account for integration tests vs unit tests +- Be specific about WHAT should be tested, not just that tests are needed From 953aba4e00d4101e6c9a0d44af0016a4a40cddff Mon Sep 17 00:00:00 2001 From: Ray Kao Date: Thu, 29 Jan 2026 23:39:07 -0500 Subject: [PATCH 2/5] feat(workflows): add GitHub Actions for Copilot setup, documentation generation, and test generation - Added from https://github.com/sitoader/AgenticWorkflows --- .github/workflows/copilot-setup-steps.yml | 27 ++++++++++ .github/workflows/copilot.generate-docs.yml | 44 +++++++++++++++++ .github/workflows/copilot.generate-tests.yml | 52 ++++++++++++++++++++ 3 files changed, 123 insertions(+) create mode 100644 .github/workflows/copilot-setup-steps.yml create mode 100644 .github/workflows/copilot.generate-docs.yml create mode 100644 .github/workflows/copilot.generate-tests.yml diff --git a/.github/workflows/copilot-setup-steps.yml b/.github/workflows/copilot-setup-steps.yml new file mode 100644 index 0000000..30ef634 --- /dev/null +++ b/.github/workflows/copilot-setup-steps.yml @@ -0,0 +1,27 @@ +name: "Copilot Setup Steps" + +# Allows you to test the setup steps from your repository's "Actions" tab +on: workflow_dispatch + +jobs: + # The job MUST be called `copilot-setup-steps` or it will not be picked up by Copilot + copilot-setup-steps: + runs-on: ubuntu-latest + # Set the permissions to the lowest permissions possible needed for *your steps*. Copilot will be given its own token for its operations. + permissions: + # If you want to clone the repository as part of your setup steps, for example to install dependencies, you'll need the `contents: read` permission. If you don't clone the repository in your setup steps, Copilot will do this for you automatically after the steps complete. + contents: read + # You can define any steps you want, and they will run before the agent starts. + # If you do not check out your code, Copilot will do this for you. + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Set up Node.js + uses: actions/setup-node@v4 + with: + node-version: "22" + cache: "npm" + + - name: Install JavaScript dependencies + run: npm ci \ No newline at end of file diff --git a/.github/workflows/copilot.generate-docs.yml b/.github/workflows/copilot.generate-docs.yml new file mode 100644 index 0000000..1a6d01c --- /dev/null +++ b/.github/workflows/copilot.generate-docs.yml @@ -0,0 +1,44 @@ +name: Generate Documentation with Copilot + +on: + push: + paths-ignore: + - 'docs/**' + - '**.md' + +jobs: + generate-docs: + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - name: Install GitHub Copilot CLI + env: + GH_TOKEN: ${{ secrets.COPILOT_CLI_TOKEN }} + run: | + curl -fsSL https://gh.io/copilot-install | bash + echo "Installed Copilot CLI version:" + copilot --version + + - name: Analyze and delegate to Copilot + env: + GH_TOKEN: ${{ secrets.COPILOT_CLI_TOKEN }} + run: | + echo "Analyzing commit ${{ github.sha }}" + echo "Loading documentation criteria from prompt..." + + PROMPT=$(cat .github/prompts/analyze-for-docs.prompt.md) + PROMPT="${PROMPT//\{COMMIT_SHA\}/${{ github.sha }}}" + PROMPT="${PROMPT//\{REPOSITORY\}/${{ github.repository }}}" + + echo "Delegating to GitHub Copilot..." + echo "- Copilot will use MCP to examine the commit" + echo "- Copilot will decide if documentation is needed" + echo "- Copilot will create an issue and assign it to itself if needed" + echo "" + + copilot -p "$PROMPT" --enable-all-github-mcp-tools --allow-all-tools diff --git a/.github/workflows/copilot.generate-tests.yml b/.github/workflows/copilot.generate-tests.yml new file mode 100644 index 0000000..1c2fc53 --- /dev/null +++ b/.github/workflows/copilot.generate-tests.yml @@ -0,0 +1,52 @@ +name: Generate Tests with Copilot + +on: + push: + paths-ignore: + - 'docs/**' + - '**.md' + - '.github/workflows/**' + - '.gitignore' + - 'LICENSE' + - '*.config.js' + - '*.config.ts' + +jobs: + generate-tests: + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - name: Install GitHub Copilot CLI + env: + GH_TOKEN: ${{ secrets.COPILOT_CLI_TOKEN }} + run: | + curl -fsSL https://gh.io/copilot-install | bash + echo "Installed Copilot CLI version:" + copilot --version + + - name: Analyze and generate tests with Copilot + env: + GH_TOKEN: ${{ secrets.COPILOT_CLI_TOKEN }} + run: | + echo "Analyzing commit ${{ github.sha }} for test coverage..." + echo "Source files changed: ${{ steps.changes.outputs.source_count }}" + echo "" + + # Load the prompt template + PROMPT=$(cat .github/prompts/analyze-for-tests.prompt.md) + PROMPT="${PROMPT//\{COMMIT_SHA\}/${{ github.sha }}}" + PROMPT="${PROMPT//\{REPOSITORY\}/${{ github.repository }}}" + + echo "Delegating to GitHub Copilot for test analysis..." + echo "- Copilot will examine the commit diff" + echo "- Copilot will check for corresponding test files" + echo "- Copilot will assess if new tests are needed" + echo "- Copilot will create an issue if tests are recommended" + echo "" + + copilot -p "$PROMPT" --enable-all-github-mcp-tools --allow-all-tools --no-ask-user From 42e199e4f1fa5c25cbdeba376dc76a43df2328c6 Mon Sep 17 00:00:00 2001 From: Ray Kao Date: Thu, 29 Jan 2026 23:39:42 -0500 Subject: [PATCH 3/5] feat(workflows): Lab docs explaining GHA workflows for automatic documentation and test generation using GitHub Copilot - Added from https://github.com/sitoader/AgenticWorkflows --- labs/workflows/copilot.generate-docs.md | 138 +++++++++++++++++ labs/workflows/copilot.generate-tests.md | 187 +++++++++++++++++++++++ 2 files changed, 325 insertions(+) create mode 100644 labs/workflows/copilot.generate-docs.md create mode 100644 labs/workflows/copilot.generate-tests.md diff --git a/labs/workflows/copilot.generate-docs.md b/labs/workflows/copilot.generate-docs.md new file mode 100644 index 0000000..ff5bbd2 --- /dev/null +++ b/labs/workflows/copilot.generate-docs.md @@ -0,0 +1,138 @@ +# Generate Documentation Workflow + +**Workflow File**: [`.github/workflows/generate-docs.yml`](../../.github/workflows/generate-docs.yml) + +## Overview + +The Generate Documentation workflow leverages GitHub Copilot CLI to analyze code changes and automatically creates documentation when necessary. Instead of relying on developers to remember to update docs, this agentic workflow handles it autonomously. + + +## How It Works + +```mermaid +flowchart TD + A[Push to Repository] --> B{Excluded files only?} + B -->|Yes| C[Skip workflow] + B -->|No| D[Install Copilot CLI] + D --> E[Load analyze-commit prompt] + E --> F[Copilot analyzes commit diff] + F --> G{Documentation needed?} + G -->|No| H[Exit - No action needed] + G -->|Yes| I[Create GitHub Issue] + I --> J[Assign Copilot Coding Agent] + J --> K[Agent implements documentation] + K --> L[PR created with docs] +``` + +### Step-by-Step Process + +1. **Triggers on every push** (excluding docs and markdown files) +2. **Installs Copilot CLI** in the GitHub Actions runner +3. **Loads the analyze-for-docs prompt** from [`.github/prompts/analyze-for-docs.prompt.md`](../../.github/prompts/analyze-for-docs.prompt.md) +4. **Copilot examines the commit diff** using MCP tools +5. **If documentation is needed** โ†’ Creates a GitHub issue and assigns Copilot +6. **Copilot Coding Agent** then implements the documentation + + +## Criteria for Documentation + +### โœ… Documentation IS Needed + +| Change Type | Example | +|-------------|---------| +| Public APIs | New REST endpoints, GraphQL mutations | +| Functions/Classes | Exported functions, public class methods | +| Complex Logic | Algorithms, business rules, data transformations | +| Architectural Changes | New services, modified data flow | +| Breaking Changes | API contract changes, removed features | + +### โŒ Documentation NOT Needed + +| Change Type | Example | +|-------------|---------| +| Minor Refactoring | Variable renames, code reorganization | +| Formatting | Whitespace, linting fixes | +| Trivial Typo Fixes | Comment typos, string corrections | +| Internal Implementation | Private methods, internal helpers | + + +## Configuration + +### Trigger Configuration + +The workflow excludes certain paths to avoid unnecessary runs: + +```yaml +on: + push: + paths-ignore: + - 'docs/**' + - '**/*.md' + - '.github/workflows/**' +``` + +### Required Secrets + +| Secret | Description | +|--------|-------------| +| `COPILOT_CLI_TOKEN` | Personal Access Token with Copilot permissions | + +--- + +## Prompt File + +The workflow uses a specialized prompt to guide Copilot's analysis: + +**Location**: [`.github/prompts/analyze-for-docs.prompt.md`](../../.github/prompts/analyze-for-docs.prompt.md) + +This prompt instructs Copilot to: +- Analyze the git diff of the latest commit +- Evaluate changes against documentation criteria +- Determine if public-facing code was added or modified +- Create a well-structured issue if documentation is warranted + + +## Example Issue Created + +When the workflow detects documentation is needed, it creates an issue like: + +```markdown +## ๐Ÿ“š Documentation Needed + +**Commit**: abc1234 +**Author**: @developer + +### Changes Requiring Documentation + +- New `/api/warehouses` endpoint added +- `Warehouse` model with 10 properties +- CRUD operations for warehouse management + +### Suggested Documentation + +1. Update API documentation with new endpoints +2. Add Warehouse model to data model docs +3. Include usage examples + +/assign @copilot +``` + + + +## Troubleshooting + +### Workflow Not Triggering + +- Verify the push includes files outside the `paths-ignore` patterns +- Check that the workflow file exists in the default branch + +### Copilot Not Creating Issues + +- Ensure `COPILOT_CLI_TOKEN` secret is configured +- Verify the token has `Copilot Requests` permission +- Check workflow logs for authentication errors + +### Agent Not Implementing Documentation + +- Confirm Copilot Coding Agent is enabled in repository settings +- Verify the issue is properly assigned to `@copilot` diff --git a/labs/workflows/copilot.generate-tests.md b/labs/workflows/copilot.generate-tests.md new file mode 100644 index 0000000..db13c76 --- /dev/null +++ b/labs/workflows/copilot.generate-tests.md @@ -0,0 +1,187 @@ +# Generate Tests Workflow + +**Workflow File**: [`.github/workflows/generate-tests.yml`](../../.github/workflows/generate-tests.yml) + +This workflow analyzes commits for missing unit test coverage and automatically creates issues for Copilot to write the tests. + + +## Overview + +The Generate Tests workflow uses GitHub Copilot CLI to examine code changes and identify when new or modified code lacks corresponding unit tests. By automating test coverage analysis, teams can maintain high code quality without manual review overhead. + + +## How It Works + +```mermaid +flowchart TD + A[Push to Repository] --> B{Source files changed?} + B -->|No| C[Skip workflow] + B -->|Yes| D[Install Copilot CLI] + D --> E[Load analyze-tests prompt] + E --> F[Copilot analyzes code changes] + F --> G{Tests missing?} + G -->|No| H[Exit - Coverage adequate] + G -->|Yes| I[Create GitHub Issue] + I --> J[Assign Copilot Coding Agent] + J --> K[Agent writes missing tests] + K --> L[PR created with tests] +``` + +### Step-by-Step Process + +1. **Triggers on every push** (excluding non-source files) +2. **Installs Copilot CLI** in the GitHub Actions runner +3. **Loads the analyze-for-tests prompt** from [`.github/prompts/analyze-for-tests.prompt.md`](../../.github/prompts/analyze-for-tests.prompt.md) +4. **Copilot checks if new code has corresponding tests** +5. **If tests are missing** โ†’ Creates a GitHub issue and assigns Copilot +6. **Copilot Coding Agent** then writes the missing tests + + +## Criteria for Tests + +### โœ… Tests ARE Needed + +| Change Type | Example | +|-------------|---------| +| New Functions/Methods | `calculateDiscount()`, `validateOrder()` | +| New Classes | `WarehouseService`, `OrderProcessor` | +| Modified Business Logic | Changed calculation formulas, updated validation | +| New API Endpoints | REST routes, GraphQL resolvers | +| Error Handling Paths | Try/catch blocks, error conditions | + +### โŒ Tests NOT Needed + +| Change Type | Example | +|-------------|---------| +| Configuration Files | `tsconfig.json`, `package.json` | +| Type Definitions Only | Interface declarations, type aliases | +| Test Files Themselves | `*.test.ts`, `*.spec.ts` | +| Documentation | README, comments, JSDoc | +| Static Assets | Images, fonts, CSS | + + +## Configuration + +### Trigger Configuration + +The workflow focuses on source code changes: + +```yaml +on: + push: + paths: + - 'api/src/**/*.ts' + - 'frontend/src/**/*.ts' + - 'frontend/src/**/*.tsx' + paths-ignore: + - '**/*.test.ts' + - '**/*.spec.ts' + - '**/*.d.ts' +``` + +### Required Secrets + +| Secret | Description | +|--------|-------------| +| `COPILOT_CLI_TOKEN` | Personal Access Token with Copilot permissions | + + + +## Prompt File + +The workflow uses a specialized prompt to guide Copilot's analysis: + +**Location**: [`.github/prompts/analyze-for-tests.prompt.md`](../../.github/prompts/analyze-for-tests.prompt.md) + +This prompt instructs Copilot to: +- Analyze the git diff for testable code changes +- Identify functions, classes, and methods without test coverage +- Evaluate if existing tests cover the modified code paths +- Create a detailed issue listing specific tests to write + + +## Example Issue Created + +When the workflow detects missing tests, it creates an issue like: + +```markdown +## ๐Ÿงช Unit Tests Needed + +**Commit**: def5678 +**Author**: @developer + +### Code Requiring Tests + +#### `api/src/routes/warehouse.ts` +- [ ] `POST /` - Create warehouse endpoint +- [ ] `GET /` - Get all warehouses +- [ ] `GET /:id` - Get warehouse by ID +- [ ] `GET /branch/:branchId` - Get warehouses by branch +- [ ] `PUT /:id` - Update warehouse +- [ ] `DELETE /:id` - Delete warehouse + +### Test File Location +`api/src/routes/warehouse.test.ts` + +### Testing Framework +Vitest with supertest for API testing + +/assign @copilot +``` + + +## Test Patterns Used + +The Copilot Coding Agent follows established testing patterns in the codebase + +### API Route Tests + +```typescript +import { describe, it, expect, beforeEach } from 'vitest'; +import request from 'supertest'; +import app from '../index'; + +describe('Warehouse Routes', () => { + describe('GET /api/warehouses', () => { + it('should return all warehouses', async () => { + const response = await request(app).get('/api/warehouses'); + expect(response.status).toBe(200); + expect(Array.isArray(response.body)).toBe(true); + }); + }); + + describe('GET /api/warehouses/:id', () => { + it('should return 404 for non-existent warehouse', async () => { + const response = await request(app).get('/api/warehouses/99999'); + expect(response.status).toBe(404); + }); + }); +}); +``` + + +## Troubleshooting + +### Workflow Not Triggering + +- Verify the push includes files matching the `paths` patterns +- Ensure changes are not exclusively in `paths-ignore` patterns +- Check that the workflow file exists in the default branch + +### Copilot Not Detecting Missing Tests + +- Review the generate-tests prompt for coverage criteria +- Ensure the code changes are substantial enough to warrant tests +- Check workflow logs for the analysis output + +### Agent Writing Incorrect Tests + +- Verify existing test patterns in the codebase are consistent +- Check that the testing framework is correctly configured +- Review the prompt for framework-specific instructions + +### Tests Failing After Generation + +- Run tests locally to identify issues +- Check for missing imports or dependencies +- Verify mock data matches the expected schema From 9a3fcea9fd6e457e71779aa61071d8f3dbd8bb71 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Fri, 30 Jan 2026 05:24:02 +0000 Subject: [PATCH 4/5] Initial plan From 397dd72dab530252246ec2f822816621990fd320 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Fri, 30 Jan 2026 05:27:16 +0000 Subject: [PATCH 5/5] Add explicit permissions to Copilot workflows for repo read and issue creation Co-authored-by: raykao <860691+raykao@users.noreply.github.com> --- .github/workflows/copilot.generate-docs.yml | 3 +++ .github/workflows/copilot.generate-tests.yml | 3 +++ 2 files changed, 6 insertions(+) diff --git a/.github/workflows/copilot.generate-docs.yml b/.github/workflows/copilot.generate-docs.yml index 1a6d01c..1f43262 100644 --- a/.github/workflows/copilot.generate-docs.yml +++ b/.github/workflows/copilot.generate-docs.yml @@ -9,6 +9,9 @@ on: jobs: generate-docs: runs-on: ubuntu-latest + permissions: + contents: read # Required to read repository content and commit diffs + issues: write # Required to create GitHub issues for documentation recommendations steps: - name: Checkout code diff --git a/.github/workflows/copilot.generate-tests.yml b/.github/workflows/copilot.generate-tests.yml index 1c2fc53..5b31fec 100644 --- a/.github/workflows/copilot.generate-tests.yml +++ b/.github/workflows/copilot.generate-tests.yml @@ -14,6 +14,9 @@ on: jobs: generate-tests: runs-on: ubuntu-latest + permissions: + contents: read # Required to read repository content and commit diffs + issues: write # Required to create GitHub issues for test coverage recommendations steps: - name: Checkout code