Improve policy validation

From &5362 (comment 665128157)

When the user clicks the "Create merge request" button, we should check to see if they have a least one branch defined. If not, then we should show the following error message.

run-compliance-ci-file-yaml-mode

Implementation

type: scan_execution_policy
name: # name is mandatory
description: ''
enabled: false
rules:
  - type: pipeline
    branches:
      - # branch is mandatory
actions:
  - scan: dast
    site_profile: ''
    scanner_profile: ''

This page may contain information related to upcoming products, features and functionality. It is important to note that the information presented is for informational purposes only, so please do not rely on the information for purchasing or planning purposes. Just like with all projects, the items mentioned on the page are subject to change or delay, and the development, release, and timing of any products, features, or functionality remain at the sole discretion of GitLab Inc.

Edited by Alexander Turinske