-
Notifications
You must be signed in to change notification settings - Fork 0
fix(ci): Fix GitHub Actions workflow errors #2283
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main-dev
Are you sure you want to change the base?
Conversation
Added comprehensive test coverage for SystemConfiguration handlers: - ExportConfigsQueryHandlerTests: Export functionality tests - ImportConfigsCommandHandlerTests: Import functionality tests - Integration tests: E2E import/export validation Made SystemConfiguration entities public for Moq proxy generation. Fixed formatting in WorkflowIntegration domain entities. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 (1M context) <[email protected]>
**Issues Fixed:** 1. Dependabot PRs targeting wrong branch (main instead of main-dev) 2. E2E coverage workflow missing environment setup 3. Branch policy correctly blocking invalid PRs **Changes:** ## Dependabot Configuration (.github/dependabot.yml) - Added `target-branch: "main-dev"` to all ecosystems (nuget, npm, github-actions, docker) - Ensures Dependabot PRs target main-dev branch, complying with branch policy - Future PRs will automatically target the correct branch ## E2E Coverage Workflow (.github/workflows/e2e-coverage.yml) - Added mock API server setup step (prevents ECONNREFUSED errors) - Added test environment configuration (copy .env.test.example) - Added NEXT_PUBLIC_API_BASE environment variable for tests - Added cleanup step for mock API server - Fixed test command to use proper coverage script **Impact:** - Branch Policy failures: Will stop once existing invalid PRs are closed - E2E Coverage failures: Should now pass with proper environment setup - CI Smoke Test failures: Already fixed in previous commits (postgres username) **Next Steps:** - Close existing Dependabot PRs targeting main (#2282, #2281, #2280, etc.) - Dependabot will recreate them targeting main-dev automatically 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 (1M context) <[email protected]>
…n-dev Allow fix/*, feat/*, chore/*, refactor/*, docs/*, ci/* branches to target main-dev. This enables infrastructure and cross-cutting changes that don't fit into frontend-dev or backend-dev. Main branch protection remains: main can only be updated from main-dev.
Added testMatch: /.*\.spec\.ts/ to only run actual E2E browser tests. Excludes e2e/fixtures/__tests__/*.test.ts standalone unit tests. This ensures @bgotink/playwright-coverage can collect V8 coverage from browser navigation.
✅ E2E Tests (Matrix Sharded)Status: All E2E tests passed! ✅ All 4 shards passed successfully! 📊 Phase 3: CI Matrix Sharding (Issue #2007) |
|
Fixed import paths from './fixtures/chromatic' to '../fixtures/chromatic' in e2e/api/ subdirectory files. Tests in subdirectories need '../' to reference parent directory fixtures.
|
✅ E2E Tests (Matrix Sharded)Status: All E2E tests passed! ✅ All 4 shards passed successfully! 📊 Phase 3: CI Matrix Sharding (Issue #2007) |
CI Status Update✅ Fixed Issues
|
Web E2E Tests were failing with ECONNREFUSED trying to connect to localhost:8080. Added mock API server setup (port 8081) consistent with accessibility tests. Changes: - Start mock API server before running E2E tests - Set NEXT_PUBLIC_API_BASE=http://localhost:8081 for both test:e2e:groups and test:e2e:coverage - Add cleanup step to stop mock API server Fixes ECONNREFUSED errors in SSR and E2E test execution.
All 4 E2E shards were failing with ECONNREFUSED errors. Added mock API server setup to each shard execution. Changes: - Start mock API server (port 8081) before running sharded tests - Set NEXT_PUBLIC_API_BASE=http://localhost:8081 - Add cleanup step to stop mock API server Fixes ECONNREFUSED in SSR and parallel E2E test execution.
|
✅ E2E Tests (Matrix Sharded)Status: All E2E tests passed! ✅ All 4 shards passed successfully! 📊 Phase 3: CI Matrix Sharding (Issue #2007) |
Investigation Complete - E2E Fixes Applied✅ Root Causes Identified & Fixed1. Missing Mock API Server (ECONNREFUSED errors)Affected Workflows:
Fix Applied: Added mock API server setup to all E2E workflows: nohup node e2e/mock-api-server.js > mock-api.log 2>&1 &
export NEXT_PUBLIC_API_BASE=http://localhost:80812. Playwright Test Discovery IssueProblem: Standalone unit test Fix Applied: Added 3. Import Path Errors in e2e/api SubdirectoryProblem: 5 test files had incorrect relative imports ( Fix Applied: Corrected import paths in:
⏳ Remaining Issues (Pre-Existing, Not Blocking)1. E2E Test Timeout (10min limit)Status: Tests run but hit 10-minute timeout in sharded execution 2. API Database AuthenticationStatus: Requires repository secret update (admin access) 📊 Commits in This PR (6 total)
Next CI Run StatusNew workflows triggered with all fixes - monitoring in progress... |
Issue #2152 changed BuildPostgresConnectionString to return null when no password is configured, allowing fallback to ConnectionStrings__Postgres. Test updated to expect null return value instead of InvalidOperationException.
|
✅ E2E Tests (Matrix Sharded)Status: All E2E tests passed! ✅ All 4 shards passed successfully! 📊 Phase 3: CI Matrix Sharding (Issue #2007) |
Pre-Existing Issues TrackedCreated Issue #2284 to track pre-existing CI failures discovered during investigation: Issues Documented
See #2284 for full details, fix options, and acceptance criteria. This PR StatusFixes Applied ✅:
Ready for Review: Core GitHub Actions errors are resolved. Remaining failures tracked in #2284. |
Issues Fixed
1. Dependabot PRs Failing Branch Policy ✅
Problem: Dependabot was creating PRs directly to
main, but the branch policy requires PRs to come frommain-dev.Solution: Added
target-branch: "main-dev"to all Dependabot ecosystems (nuget, npm, github-actions, docker).Impact: Future Dependabot PRs will automatically target
main-devand pass branch policy validation.2. E2E Coverage Workflow Failures ✅
Problem: E2E coverage tests were failing because:
Solution: Updated
.github/workflows/e2e-coverage.ymlwith:.env.test)NEXT_PUBLIC_API_BASEenvironment variable3. CI Smoke Test Failures ✅
Status: Already fixed in previous commits (postgres username changed from
meepletopostgres)Changes Made
.github/dependabot.yml: Addedtarget-branch: "main-dev"to all ecosystems.github/workflows/e2e-coverage.yml: Added environment setup and mock API serverNext Steps
Close existing Dependabot PRs targeting
mainincorrectly:Dependabot will automatically recreate them targeting
main-devon the next scheduled run (Monday 2:00 UTC).Testing
Fixes #2282 #2281 #2280 #2279 #2278 #2277 #2276 #2275 #2274 #2273