Align license compliance `deny` classification outcome with user expectations - Prevent MR from being mergable in UI
See: #196845 (closed)
Don't allow MR to be merged if any license policies have classification
as denied
. This would mean that for a particular license in the Policy
tab that has a rule of Denied
that is then detected in the projcect.
##Implementation:
See #196845 (comment 336410150) for a complete code walkthrough:
What we need to do:
1.) Add a new state.key
in https://gitlab.com/gitlab-org/gitlab/-/blob/master/app/assets/javascripts/vue_merge_request_widget/stores/get_state_key.js
2.) We need to add a new mapping in https://gitlab.com/gitlab-org/gitlab/-/blob/master/app/assets/javascripts/vue_merge_request_widget/stores/state_maps.js
3.) Create the new Vue component called mr_widget_policy_violation
and put it in https://gitlab.com/gitlab-org/gitlab/-/tree/master/app/assets/javascripts/vue_merge_request_widget/components/states
4.) Write unit tests