class Syskit::Test::NetworkManipulation::NoConfigureFixedPoint

Constants

Info

Attributes

info[R]
tasks[R]

Public Class Methods

new(tasks) click to toggle source
# File lib/syskit/test/network_manipulation.rb, line 695
def initialize(tasks)
    @tasks = tasks
    @info = Hash.new
    tasks.each do |t|
        precedence = t.start_event.parent_objects(Roby::EventStructure::SyskitConfigurationPrecedence).to_a
        missing = precedence.find_all { |ev| !ev.emitted? }
        info[t] = Info.new(
            t.ready_for_setup?,
            t.list_unset_arguments,
            precedence, missing)
    end
end

Public Instance Methods

pretty_print(pp) click to toggle source
# File lib/syskit/test/network_manipulation.rb, line 707
def pretty_print(pp)
    pp.text "cannot find an ordering to configure #{tasks.size} tasks"
    tasks.each do |t|
        pp.breakable
        t.pretty_print(pp)

        info = self.info[t]
        pp.nest(2) do
            pp.breakable
            pp.text "ready_for_setup? #{info.ready_for_setup}"
            pp.breakable
            if info.missing_arguments.empty?
                pp.text "is fully instanciated"
            else
                pp.text "missing_arguments: #{info.missing_arguments.join(", ")}"
            end

            pp.breakable
            if info.precedence.empty?
                pp.text "has no should_configure_after constraint"
            else
                pp.text "is waiting for #{info.missing.size} events to happen before continuing, among #{info.precedence.size}"
                pp.nest(2) do
                    info.missing.each do |ev|
                        pp.breakable
                        ev.pretty_print(pp)
                    end
                end
            end
        end
    end
end