Sha256: 949757650e8d4d71ae9f6dbf4d5a3ed9fe95557da156e30761fdd1f644a13641
Contents?: true
Size: 800 Bytes
Versions: 20
Compression:
Stored size: 800 Bytes
Contents
# frozen_string_literal: true require_relative 'base_policy' require_relative '../entity_builders/summary_builder' module Gitlab module Triage module Policies class SummaryPolicy < BasePolicy # Build a summary from several rules policies def build_summary action = actions[:summarize] issues = resources.map do |inner_policy_spec, inner_resources| Policies::RulePolicy.new( type, inner_policy_spec, inner_resources, network) .build_summary end EntityBuilders::SummaryBuilder.new( type: type, action: action, resources: issues.select(&:any_resources?), network: network, separator: "\n\n") end end end end end
Version data entries
20 entries across 20 versions & 2 rubygems