Refactor: Use create service when creating environment through REST API
Using the same create service for both REST API and GraphQL improves the consistency and DRY.
显示
- app/models/environment.rb 12 个添加, 4 个删除app/models/environment.rb
- app/services/environments/create_service.rb 4 个添加, 1 个删除app/services/environments/create_service.rb
- config/feature_flags/beta/new_default_for_auto_stop.yml 9 个添加, 0 个删除config/feature_flags/beta/new_default_for_auto_stop.yml
- doc/ci/environments/_index.md 12 个添加, 0 个删除doc/ci/environments/_index.md
- lib/api/environments.rb 1 个添加, 1 个删除lib/api/environments.rb
- spec/models/environment_spec.rb 44 个添加, 0 个删除spec/models/environment_spec.rb
- spec/requests/api/environments_spec.rb 10 个添加, 1 个删除spec/requests/api/environments_spec.rb
- spec/services/environments/create_service_spec.rb 117 个添加, 1 个删除spec/services/environments/create_service_spec.rb
加载中
想要评论请 注册 或 登录