Class: Loadrunner::CommandLine
- Inherits:
-
SuperDocopt::Base
- Object
- SuperDocopt::Base
- Loadrunner::CommandLine
- Includes:
- Colsole
- Defined in:
- lib/loadrunner/command_line.rb
Overview
Handles the command line interface
Instance Method Summary collapse
Instance Method Details
#event ⇒ Object
18 19 20 21 22 |
# File 'lib/loadrunner/command_line.rb', line 18 def event client = Client.new client_opts response = client.send_event args['EVENT'], payload_opts show response end |
#payload ⇒ Object
24 25 26 27 28 29 30 31 32 |
# File 'lib/loadrunner/command_line.rb', line 24 def payload client = Client.new client_opts file = args['FILE'] raise ArgumentError, "File not found: #{file}" unless File.exist? file json = File.read file response = client.send_payload args['EVENT'], json show response end |