Skip to content

Commit 7ba4a5f

Browse files
Copilotstephentoub
andcommitted
Add explicit build and test requirements to instructions
Co-authored-by: stephentoub <2642209+stephentoub@users.noreply.github.com>
1 parent e86dd9a commit 7ba4a5f

1 file changed

Lines changed: 23 additions & 0 deletions

File tree

.github/copilot-instructions.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,19 @@
22

33
This repository contains the official C# SDK for the Model Context Protocol (MCP), enabling .NET applications to implement and interact with MCP clients and servers.
44

5+
## Critical: Always Build and Test
6+
7+
**ALWAYS build and run tests before declaring any task complete or making a pull request.**
8+
9+
When making code changes:
10+
1. **Build first**: Run `dotnet build` or `make build` to ensure the code compiles without errors
11+
2. **Run tests**: Execute `dotnet test --filter '(Execution!=Manual)'` or `make test` to verify all tests pass
12+
3. **Fix issues**: Address any build errors or test failures before proceeding
13+
4. **Verify iteratively**: Build and test frequently during development, not just at the end
14+
5. **Check warnings**: Treat warnings as errors - the build is configured with `TreatWarningsAsErrors=true`
15+
16+
**Never skip these steps.** Even small changes can have unexpected impacts. A passing build and test suite is the minimum bar for any code change.
17+
518
## Project Overview
619

720
The SDK consists of three main packages:
@@ -97,6 +110,16 @@ The SDK consists of three main packages:
97110
- **Test**: `dotnet test` or `make test`
98111
- **Clean**: `dotnet clean` or `make clean`
99112

113+
### Development Workflow
114+
**Critical**: Always follow this workflow when making changes:
115+
1. Make code changes
116+
2. Build immediately: `dotnet build` - fix any compilation errors
117+
3. Run tests: `dotnet test --filter '(Execution!=Manual)'` - fix any test failures
118+
4. Repeat steps 1-3 iteratively as you develop
119+
5. Only after successful build and tests should you consider the change complete
120+
121+
Do not skip or defer building and testing. These are mandatory steps for every code change, no matter how small.
122+
100123
### SDK Requirements
101124
- The repo currently requires the .NET SDK 10.0 to build and run tests.
102125
- Target frameworks: .NET 10.0, .NET 9.0, .NET 8.0, .NET Standard 2.0

0 commit comments

Comments
 (0)