Add specs for REST API create approval rule with v2 rules

Add test coverage for REST API create approval rule endpoint with v2 approval rules enabled.

Why

The REST API endpoints are tested with the v2_approval_rules feature flag disabled by default in rspec. We need explicit test coverage to ensure the create endpoint works correctly when v2 rules are enabled.

What

Add specs to test:

  • Creating v2 approval rules via REST API with feature flag enabled
  • Verify v2 rule attributes are properly set
  • Verify v1 rules are not created when flag is enabled
  • Error handling and validation with v2 rules

Related

  • Refactor approval rules create service to only write v1 or v2 rules (#576308 (closed))
Edited Jan 20, 2026 by 🤖 GitLab Bot 🤖
Assignee Loading
Time tracking Loading