| name | build-ci |
| description | Build commands, CI workflows, NuGet restore, and troubleshooting. Use when building the project, restoring NuGet packages, running tests, publishing, debugging CI/CD pipelines, or troubleshooting build errors like NU1301. Covers: dotnet restore, dotnet build Tests --no-restore, dotnet publish, self-hosted runners, internal NuGet sources, NU1301 resolution, test connection failures. stages: test-implementation, test-validation |
Build, CI & Troubleshooting
When to Use
- Building the project
- Restoring NuGet packages
- Running or publishing tests
- Debugging CI/CD pipeline failures
- Troubleshooting NU1301 or other build errors
Environment Requirements
CRITICAL: This project requires access to internal NuGet package sources at gears.insideigt.com:9099. Building will fail outside the corporate network or on self-hosted runners without this access.
Build Commands (In Order)
Always run from the repository root:
1. Restore NuGet Packages (REQUIRED first step, ~50 seconds)
dotnet restore
- Must complete before building
- Accesses internal NuGet sources: Tools, GGAMF, and NuGet.org
- Error NU1301 = internal NuGet server unreachable
2. Build the Project (~10-30 seconds)
dotnet build Tests --no-restore
--no-restore is CRITICAL — always include after running restore
- Builds the Tests project only (not the solution)
3. Run Tests (requires EGM connection)
dotnet run --project Tests -- [NUnitLite arguments]
- Requires running EGM with UTP connection (default:
localhost:5780)
--where "cat==YourCategory" for specific categories
--workers=4 for parallel execution
- Tests fail without EGM — expected in CI
4. Publish for Deployment (~15-45 seconds)
dotnet publish -c Release
- Output:
Tests/bin/Release/net8.0/win-x64/publish/Tests.exe
- Self-contained, single-file Windows x64 executable
CI Workflow Details
build-test.yml
- Triggers: PRs to main when
.cs or .csproj files change
- Runs on:
self-hosted runners with upm-deploy label (required for NuGet access)
- Steps: Ensure dotnet 8.x → Checkout →
dotnet restore → dotnet build Tests --no-restore
- Tests are NOT run in CI — only build validation
bypass-build-test.yml
- Runs when no code files changed (documentation-only PRs)
- Ensures "Build & test" status check passes
- Runs on
ubuntu-latest
Common Issues
NU1301 NuGet Error
- Symptom:
Resource temporarily unavailable (gears.insideigt.com:9099)
- Cause: Internal NuGet server not accessible
- Fix: Must be on corporate network or use self-hosted runner. Not a code problem — never attempt code workarounds
Test Connection Failures
- Symptom: Tests fail with connection/timeout errors
- Cause: No UTP connection at configured address/port
- Fix: Verify
appsettings.json UTP settings. All tests require active UTP connection
Build Fails After Restore
- Symptom: Build fails even after successful restore
- Cause: Missing
--no-restore flag
- Fix: Always use
dotnet build Tests --no-restore
Outdated NuGet Packages
- Fix:
dotnet list package --outdated then dotnet add package <PackageName>
Critical Constraints
- Runtime identifier must remain
win-x64 (games run on Windows only)
- Node.js/npm not available — expected; uses .NET build system only
- Never attempt workarounds for NU1301 — it's an environment issue