System Hook Tests should include all options

From a customer: https://gitlab.zendesk.com/agent/tickets/81736

I have upgraded my test environment to 9.5.1-ee, I'm testing out Web hooks. The functionality in this area changed, and now I cannot test webhooks with the default configuration. To do this I setup a valid URL, under triggers I have everything unchecked as I intend to use this for a hook when adding users. When I select any of the options under test I get various errors: Repository Update Event: Hook execution failed: Ensure project "NAMESPACE / PROJECT" has commits Push Events: same message as the previous Tag push events: Hook execution failed: Ensure project "NAMESPACE / PROJECT" has tags

In my case, I don't care about any of those, I want to make sure the hooks will generally work, like it previously did. I would expect there to be a general option, or a test option for each feature.

Repro steps:

  1. Be an admin.
  2. Log in to admin interface.
  3. Go to System Hooks.
  4. Create a hook with no "optional events" (do not check the Repository update events/Push events/Tag push events options)
  5. Navigate to the new hook you just added.
  6. Choose the Test Field.
  7. Options only appear for the "optional events".

Solution:

  1. Make a general test event that will send a general request with values set for everything.
  2. Make each feature have it's own test.