Title#
feat: extract hardcoded org and label constants to TenantConfigService (#353)
Problem#
Several services (ArtefactsService, PhaseHooksService, GitHubAdapter) used hardcoded string constants for the GitHub org (GH_ORG) and label names ('in-refinement', 'refined', 'in-review', 'agent-blocked'). This made org and label names non-configurable per tenant.
Task / Link#
Closes #353
Changes#
- Removed
GH_ORGexport fromsrc/config/constants.ts;ARTEFACTS_REPOnow uses an inline string ArtefactsService: injectedTenantConfigService; replaced allGH_ORGusages withtenantConfig.getConfig().orgPhaseHooksService: injectedTenantConfigService; replaced 5 hardcoded label strings withtenantConfig.getConfig().labels.*GitHubAdapter: injectedTenantConfigService; replaced 3'in-refinement'comparisons withtenantConfig.getConfig().labels.inRefinement- Module files (
ArtefactsModule,PhaseHooksModule,WebhookModule) updated to importTenantModule - Unit tests updated with
TenantConfigServicemock in all affected spec files and integration test utils
Notes#
- Depends on #348 (
TenantConfigServiceimplementation) — merged first ARTEFACTS_REPOremains a hardcoded infrastructure constant (not tenant-specific)- 6 pre-existing watchdog test failures on
masterare unrelated to this change
Testing#
npm run lint— passednpm run test— 750 tests pass; 6 pre-existing watchdog failures unchanged