Skip to content

Refactors for WebHook specs and Smocker tooling

Sean Gregory requested to merge e2e/webhook-consolidate-helpers into master

What does this MR do and why?

This MR

  • consolidates behaviors for project and group web hook specs
    • this reduces duplication of logic and makes the specs more consistent
  • removes web hook behaviors from the Smocker tooling directly
    • QA::Vendor::Smocker::SmockerApi is agnostic to web hooks and should only encapsulate related logic.
  • adds a mixin to setup the Smocker api on the WebHook resource classes themself, as opposed to adding methods to the spec file.
    • This provides better encapsulation around what the resource is responsible for.

This MR is also dependent on !110430 (merged)

How to set up and validate locally

From gitlab directory with docker running

  1. cd qa
  2. bundle exec ./bin/qa Test::Instance::All -- qa/specs/features/api/1_manage/integrations/webhook_events_spec.rb
  3. bundle exec ./bin/qa Test::Instance::All -- qa/specs/features/ee/api/1_manage/integrations/group_webhook_events_spec.rb

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Sean Gregory

Merge request reports