Class: MakersToolbelt::RandomizeBytes
- Inherits:
-
Object
- Object
- MakersToolbelt::RandomizeBytes
- Defined in:
- lib/makers_toolbelt/randomize_bytes.rb
Constant Summary collapse
- RANDOMIZE_BYTES_PATH =
-> (cohort_id) do "/api/v1/cohorts/#{cohort_id}/randomize_bytes" end
Instance Method Summary collapse
-
#initialize(client: nil, interface: nil) ⇒ RandomizeBytes
constructor
A new instance of RandomizeBytes.
- #run ⇒ Object
Constructor Details
#initialize(client: nil, interface: nil) ⇒ RandomizeBytes
Returns a new instance of RandomizeBytes.
14 15 16 17 |
# File 'lib/makers_toolbelt/randomize_bytes.rb', line 14 def initialize(client: nil, interface: nil) @interface = interface || CommandLine::Interface @client = client || HubClient.new end |
Instance Method Details
#run ⇒ Object
19 20 21 22 23 |
# File 'lib/makers_toolbelt/randomize_bytes.rb', line 19 def run = interface.ask_questions(:randomize_bytes) response = client.post(**) output(response) end |