class TurboTest::Command::List

Public Instance Methods

call() click to toggle source

Prepare the environment and run the controller.

# File lib/turbo_test/command/list.rb, line 43
def call
        path = @options[:configuration]
        full_path = File.expand_path(path)
        
        configuration = Configuration.new
        
        if File.exist?(full_path)
                configuration.load(full_path)
        end
        
        configuration.finalize!
        
        configuration.jobs.each do |klass, path, **options|
                if options&.any?
                        puts "#{klass}: #{path} #{options.inspect}"
                else
                        puts "#{klass}: #{path}"
                end
        end
end