gitlab-org--gitlab-foss/lib/gitlab/chat/responder/base.rb
James Fargher 2d19b1adef Move ChatOps to Core
ChatOps used to be in the Ultimate tier.
2019-02-20 21:29:48 +00:00

40 lines
849 B
Ruby

# frozen_string_literal: true
module Gitlab
module Chat
module Responder
class Base
attr_reader :build
# build - The `Ci::Build` that was executed.
def initialize(build)
@build = build
end
def pipeline
build.pipeline
end
def project
pipeline.project
end
def success(*)
raise NotImplementedError, 'You must implement #success(output)'
end
def failure
raise NotImplementedError, 'You must implement #failure'
end
def send_response(output)
raise NotImplementedError, 'You must implement #send_response(output)'
end
def scheduled_output
raise NotImplementedError, 'You must implement #scheduled_output'
end
end
end
end
end