gitlab-org--gitlab-foss/spec/models
Nick Thomas a5a444906d Fix the project auto devops API
If `project_auto_devops.enabled` is nil for a project, when setting any
auto devops values via the API, we try to create a new row in the DB,
instead of re-using the existing one. This leads to the project_id
being set to nil, and the database `NOT NULL` constraint leading to a
500 response.

This commit resolves the issue by correctly detecting the presence of a
ProjectAutoDevops row and re-using it. Persistence is also moved away
from explicit `update!` calls and into relying on `autosave: true` on
the model.
2019-07-19 21:39:26 +00:00
..
application_setting
badges
blob_viewer
ci Allow use of legacy triggers with feature flag 2019-07-15 15:05:22 +02:00
clusters Enable GitLabb runner to be uninstalled from cluster 2019-07-16 16:11:10 +00:00
concerns Fix the project auto devops API 2019-07-19 21:39:26 +00:00
conversational_development_index
cycle_analytics Add code review remarks 2019-07-16 18:45:15 +02:00
diff_viewer
error_tracking
hooks
issue
members
merge_request
namespace
network
postgresql
project_services
protected_branch
releases
serverless
uploads
ability_spec.rb
abuse_report_spec.rb
active_session_spec.rb Do Redis lookup in batches in ActiveSession.sessions_from_ids 2019-07-17 11:07:26 +00:00
appearance_spec.rb
application_record_spec.rb
application_setting_spec.rb
award_emoji_spec.rb
badge_spec.rb
blob_spec.rb
board_group_recent_visit_spec.rb
board_project_recent_visit_spec.rb
board_spec.rb
broadcast_message_spec.rb
chat_name_spec.rb
chat_team_spec.rb
commit_collection_spec.rb
commit_range_spec.rb
commit_spec.rb
commit_status_spec.rb
compare_spec.rb
container_repository_spec.rb
deploy_key_spec.rb
deploy_keys_project_spec.rb
deploy_token_spec.rb
deployment_metrics_spec.rb
deployment_spec.rb
diff_discussion_spec.rb
diff_note_spec.rb
discussion_spec.rb
email_spec.rb
environment_spec.rb Introduce predictable environment slugs 2019-07-19 11:33:07 +10:00
environment_status_spec.rb
event_collection_spec.rb
event_spec.rb
external_issue_spec.rb
fork_network_member_spec.rb
fork_network_spec.rb
generic_commit_status_spec.rb
global_milestone_spec.rb
gpg_key_spec.rb
gpg_key_subkey_spec.rb
gpg_signature_spec.rb
group_custom_attribute_spec.rb
group_label_spec.rb
group_milestone_spec.rb
group_spec.rb
guest_spec.rb
identity_spec.rb
import_export_upload_spec.rb
instance_configuration_spec.rb
internal_id_spec.rb
issue_collection_spec.rb
issue_spec.rb
key_spec.rb
label_link_spec.rb
label_note_spec.rb
label_priority_spec.rb
label_spec.rb
legacy_diff_discussion_spec.rb
lfs_download_object_spec.rb
lfs_file_lock_spec.rb
lfs_object_spec.rb
lfs_objects_project_spec.rb
license_template_spec.rb
list_spec.rb
member_spec.rb
merge_request_diff_commit_spec.rb
merge_request_diff_file_spec.rb
merge_request_diff_spec.rb
merge_request_spec.rb Add commit_id to AttributeCleaner::ALLOWED_REFERENCES 2019-07-15 10:30:39 +01:00
milestone_spec.rb
namespace_spec.rb
note_diff_file_spec.rb
note_spec.rb
notification_recipient_spec.rb
notification_setting_spec.rb
pages_domain_acme_order_spec.rb
pages_domain_spec.rb
personal_access_token_spec.rb
pool_repository_spec.rb
programming_language_spec.rb
project_authorization_spec.rb
project_auto_devops_spec.rb
project_ci_cd_setting_spec.rb
project_custom_attribute_spec.rb
project_daily_statistic_spec.rb
project_deploy_token_spec.rb
project_feature_spec.rb Fix wrong pages access level default 2019-07-17 12:56:58 +00:00
project_group_link_spec.rb
project_import_data_spec.rb
project_import_state_spec.rb
project_label_spec.rb
project_metrics_setting_spec.rb
project_repository_spec.rb
project_snippet_spec.rb
project_spec.rb Fix typo "beetween" in timeout validation message 2019-07-13 13:29:47 +00:00
project_statistics_spec.rb
project_team_spec.rb
project_wiki_spec.rb
prometheus_metric_spec.rb
protectable_dropdown_spec.rb
protected_branch_spec.rb
protected_tag_spec.rb
push_event_payload_spec.rb
push_event_spec.rb
redirect_route_spec.rb
release_spec.rb
remote_mirror_spec.rb
repository_language_spec.rb
repository_spec.rb
resource_label_event_spec.rb
route_spec.rb
sent_notification_spec.rb
service_spec.rb
shard_spec.rb
snippet_blob_spec.rb
snippet_spec.rb
spam_log_spec.rb
ssh_host_key_spec.rb
subscription_spec.rb
suggestion_spec.rb
system_note_metadata_spec.rb
term_agreement_spec.rb
timelog_spec.rb
todo_spec.rb
tree_spec.rb
trending_project_spec.rb
upload_spec.rb
user_agent_detail_spec.rb
user_callout_spec.rb
user_custom_attribute_spec.rb
user_interacted_project_spec.rb
user_preference_spec.rb
user_spec.rb Migrate null values for users.private_profile 2019-07-15 21:07:54 +00:00
user_status_spec.rb
wiki_directory_spec.rb
wiki_page_spec.rb