feat(integrations): Azure DevOps resource-type and tag enums (PR 1/N)#7621
feat(integrations): Azure DevOps resource-type and tag enums (PR 1/N)#7621asaphko wants to merge 8 commits into
Conversation
…gration First plan in the stacked-PRs implementation of the Azure DevOps integration spec. Covers the foundational enum extensions: AZURE_DEVOPS_PULL_REQUEST and AZURE_DEVOPS_WORK_ITEM in ResourceType plus AZURE_DEVOPS in TagType, with their migrations. No behaviour change; later PRs in the stack build on these symbols. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Add AZURE_DEVOPS_PULL_REQUEST and AZURE_DEVOPS_WORK_ITEM to ResourceType plus an AZURE_DEVOPS_RESOURCE_TYPES tuple for downstream use, mirroring the existing GitLab pattern. Bumps the type column's max_length from 20 to 30 to fit the new value lengths. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
… spec Align the design spec with TagType.AZURE_DEVOPS and the one-product-name-token pattern the GitHub and GitLab integrations follow. The plan doc and the source/test changes for this rename live in the two preceding commits. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…vOps choices Add migration recording AZURE_DEVOPS_PULL_REQUEST and AZURE_DEVOPS_WORK_ITEM in the choices list for the type column, and widening max_length from 20 to 30 to fit the longest new value. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Add the AZURE_DEVOPS TagType so the Azure DevOps integration can tag features with system tags reflecting upstream PR / work-item state in later PRs. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Add migration recording AZURE_DEVOPS in the choices list for Tag.type. No column shape change. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
The flagsmith-lint-tests pre-commit hook requires "# Given", "# When", and "# Then" as three separate marker lines in every test. The Azure DevOps PR-1 micro-tests originally used the combined "# Given / When / Then" shorthand for trivial one-assert cases; split them into proper three-phase structure and accept the accompanying ruff format change. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
The cleanup in d752544 missed one site where the test body still used "# Given / When". Split it into proper three-marker form to match the rest of the file. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub. 3 Skipped Deployments
|
There was a problem hiding this comment.
Code Review
This pull request introduces foundational changes for the Azure DevOps integration. It adds the AZURE_DEVOPS_PULL_REQUEST and AZURE_DEVOPS_WORK_ITEM resource types to ResourceType, increases the maximum length of the resource type field, and adds AZURE_DEVOPS to TagType. It also includes the corresponding Django database migrations, unit tests, and updates to the integration plan and design specifications. There are no review comments to address, and the changes look solid and well-tested.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## feat/azure-devops-spec #7621 +/- ##
=========================================================
Coverage ? 98.52%
=========================================================
Files ? 1443
Lines ? 54803
Branches ? 0
=========================================================
Hits ? 53993
Misses ? 810
Partials ? 0 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Summary
PR 1 of the stacked Azure DevOps integration rollout. Foundational enum extensions only — no behaviour change, no new app code. Everything in this PR is referenced by subsequent PRs in the stack.
ResourceType.AZURE_DEVOPS_PULL_REQUESTandResourceType.AZURE_DEVOPS_WORK_ITEMadded toapi/features/feature_external_resources/models.py, alongside anAZURE_DEVOPS_RESOURCE_TYPEStuple mirroringGITLAB_RESOURCE_TYPES.FeatureExternalResource.type.max_lengthwidened 20 → 30 to fit the new values (AZURE_DEVOPS_PULL_REQUESTis 25 chars). Metadata-only column change on Postgres.TagType.AZURE_DEVOPSadded toapi/projects/tags/models.py.0004_add_azure_resource_types.py,0010_add_azure_devops_tag_type.py).Stack
This PR targets
feat/azure-devops-spec(#7620). The spec PR should land first, then this branch can be retargeted atmain.Plan for this PR:
docs/superpowers/plans/2026-05-28-azure-devops-01-resource-types.md.Naming note
Resource type values use
AZURE_DEVOPS_*(not bareAZURE_*) for consistency withTagType.AZURE_DEVOPSand to disambiguate from other Microsoft "Azure" products. Renaming after a migration ships is painful, so locking the name in this PR.Test plan
make lintcleanmake typecheckcleanmake test opts='-n0 tests/unit/features/test_unit_feature_external_resources_models.py tests/unit/projects/tags/test_unit_projects_tags_models.py -v'— 8 passedmake test opts='tests/unit/integrations/gitlab tests/unit/features/test_unit_feature_external_resources_views.py tests/unit/features/test_migrations.py'— all passmanage.py makemigrations --check --dry-run feature_external_resources tags—No changes detected🤖 Generated with Claude Code