Thank you for your interest in contributing to DrawTogether.NET! This guide will help you set up your development environment and understand the project's development workflow.
- .NET 9 SDK
- Docker Desktop (for running dependencies via Aspire)
- Git
Start the application with all its dependencies using .NET Aspire:
dotnet run --project src/DrawTogether.AppHost/DrawTogether.AppHost.csprojThis automatically:
- Starts SQL Server in a container
- Runs database migrations via the MigrationService
- Launches the DrawTogether web application
- Opens the Aspire dashboard in your browser
The Aspire dashboard shows all running services with their statuses and endpoints.
When running via Aspire (the recommended approach), database migrations are automatically applied by the DrawTogether.MigrationService before the main application starts. You do not need to manually run dotnet ef database update.
When you modify the database model (Entity Framework entities), create a new migration:
cd ./src/DrawTogether/
dotnet ef migrations add YourMigrationNameThis generates migration files in src/DrawTogether/Data/Migrations/.
If you need to test migrations against a standalone database (not via Aspire):
cd ./src/DrawTogether/
dotnet ef database updateTo generate a SQL script for manual deployment:
cd ./src/DrawTogether/
dotnet ef migrations scriptDrawTogether.NET can use MailGun for sending emails (via FluentEmail.Mailgun). This is optional - the application works without email configured.
To enable email:
cd ./src/DrawTogether/
dotnet user-secrets set "EmailSettings:MailgunDomain" "<your-mailgun-domain>"
dotnet user-secrets set "EmailSettings:MailgunApiKey" "<your-mailgun-api-key>"If these settings are not provided, DrawTogether.NET will run without email functionality.
DrawTogether.NET has comprehensive test coverage using xUnit, Playwright, and Aspire integration tests.
dotnet test- DrawTogether.Tests - Unit and integration tests
- DrawTogether.End2End.Tests - End-to-end Playwright tests
For detailed information on authoring tests:
- Aspire Integration Tests Guide - How to write integration tests using .NET Aspire
- Blazor Playwright Tests Guide - How to write UI tests using Playwright
- Follow standard C# coding conventions
- Use meaningful variable and method names
- Add XML documentation comments for public APIs
- Keep methods focused and concise
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Make your changes
- Ensure all tests pass (
dotnet test) - Commit your changes (
git commit -m 'Add amazing feature') - Push to your branch (
git push origin feature/amazing-feature) - Open a Pull Request
- Provide a clear description of the changes
- Reference any related issues
- Ensure all CI checks pass
- Keep PRs focused on a single feature or fix
- Update documentation as needed
If you have questions or encounter issues:
- Check the existing issues
- Review the documentation
- Open a new issue with a clear description and reproduction steps
By contributing, you agree that your contributions will be licensed under the same license as the project.