blob: 9c56aa67e20def8f5b7e6c7175ee177ef9b0d918 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
# frozen_string_literal: true
module Ci
class Processable < ::CommitStatus
has_many :needs, class_name: 'Ci::BuildNeed', foreign_key: :build_id, inverse_of: :build
accepts_nested_attributes_for :needs
scope :preload_needs, -> { preload(:needs) }
validates :type, presence: true
def schedulable?
raise NotImplementedError
end
def action?
raise NotImplementedError
end
def when
read_attribute(:when) || 'on_success'
end
def expanded_environment_name
raise NotImplementedError
end
def scoped_variables_hash
raise NotImplementedError
end
end
end
|