Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Oct 14, 2025

Overview

This PR adds the unit tests infrastructure and GitHub Actions workflow from the main branch to the start branch, enabling automated testing and validation for the starter version of the repository.

Changes

GitHub Actions Workflow

Added .github/workflows/unit-tests.yml with automated testing that runs on both main and start branches. The workflow includes:

  • Package Restore and Build: Validates NuGet package compatibility and builds the .NET solution in Release configuration
  • Bicep Deployment Validation: Validates Azure Bicep infrastructure-as-code files for syntax and compilation errors
  • Deployment What-If Analysis: Optional Azure deployment validation (runs only if Azure credentials are configured)
  • Code Quality Checks: Verifies build warnings and code formatting issues

The workflow triggers on:

  • Pushes to main or start branches
  • Pull requests to main or start branches
  • Manual workflow dispatch

Documentation

Added comprehensive testing documentation:

  • .github/TESTING_GUIDE.md: Step-by-step guide for testing the application in GitHub Codespaces, including local validation, deployment, and running the app
  • .github/UNIT_TESTS.md: Detailed documentation of the unit test jobs, their purpose, and success criteria

Configuration Updates

  • Updated .gitignore to exclude Bicep compiled output (infra/main.json)
  • Added Unit Tests workflow badge to README.md to display build status

Testing

All validation steps pass successfully:

  • ✅ .NET Aspire workload installation
  • ✅ NuGet package restore
  • ✅ Solution build (Release configuration)
  • ✅ Bicep file compilation and validation

The start branch now has the same automated testing capabilities as the main branch, ensuring consistent code quality and build validation across both branches.

Related Issue

Closes #[issue number] - Add unit tests to start branch

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • aka.ms
    • Triggering command: bicep build main.bicep (dns block)
    • Triggering command: bicep build ./infra/main.bicep --stdout (dns block)

If you need me to access, download, or install something from one of these locations, you can either:

Original prompt

This section details on the original issue you should resolve

<issue_title>add unit tests to start branch</issue_title>
<issue_description>The unit tests in main branch need to be applied to start branch as well</issue_description>

<agent_instructions>the existing GitHub Actions are in main branch. These need to be applied and work for start branch as well.</agent_instructions>

Comments on the Issue (you are @copilot in this section)

Fixes #82


💬 Share your feedback on Copilot coding agent for the chance to win a $200 gift card! Click here to start the survey.

Copilot AI and others added 2 commits October 14, 2025 17:29
Co-authored-by: markjbrown <800166+markjbrown@users.noreply.github.com>
Co-authored-by: markjbrown <800166+markjbrown@users.noreply.github.com>
@markjbrown markjbrown marked this pull request as ready for review October 14, 2025 17:32
Copilot AI changed the title [WIP] Add unit tests to start branch Add unit tests and GitHub Actions workflow to start branch Oct 14, 2025
Copilot AI requested a review from markjbrown October 14, 2025 17:34
@markjbrown markjbrown merged commit fe61ec5 into start Oct 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants