Method: Fog::Compute::Linode::Mock#avail_stackscripts
- Defined in:
- lib/fog/linode/requests/compute/avail_stackscripts.rb
#avail_stackscripts(options = {}) ⇒ Object
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 |
# File 'lib/fog/linode/requests/compute/avail_stackscripts.rb', line 17 def avail_stackscripts(={}) response = Excon::Response.new response.status = 200 body = { "ERRORARRAY" => [], "ACTION" => "avail.stackscripts" } mock_stackscripts = [] 10.times do stackscript_id = rand(1..200) mock_stackscripts << create_mock_stackscript(stackscript_id) end response.body = body.merge("DATA" => mock_stackscripts) response end |