Sha256: def13cc20d7a3e957df38cd48bfb4f8360751c99c3df7b82244345a70ca1ec69
Contents?: true
Size: 508 Bytes
Versions: 56
Compression:
Stored size: 508 Bytes
Contents
module CLIHelpers def cli Appsignal::CLI end def run_cli(command, options = {}) cli.run(format_cli_arguments_and_options(command, options)) end def format_cli_arguments_and_options(command, options = {}) [*command].tap do |o| options.each do |key, value| o << "--#{key}=#{value}" end end end def set_input(value) $stdin.puts value end def prepare_input # Prepare the input by rewinding the pointer in the StringIO $stdin.rewind end end
Version data entries
56 entries across 56 versions & 1 rubygems