fog-joyent 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (110) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +9 -0
  3. data/.rubocop.yml +20 -0
  4. data/.rubocop_todo.yml +436 -0
  5. data/.ruby-gemset +1 -0
  6. data/.ruby-version +1 -0
  7. data/.travis.yml +26 -0
  8. data/CONTRIBUTING.md +18 -0
  9. data/CONTRIBUTORS.md +17 -0
  10. data/Gemfile +4 -0
  11. data/LICENSE.md +10 -0
  12. data/README.md +29 -0
  13. data/Rakefile +12 -0
  14. data/fog-joyent.gemspec +29 -0
  15. data/lib/fog/bin/joyent.rb +33 -0
  16. data/lib/fog/joyent.rb +16 -0
  17. data/lib/fog/joyent/analytics.rb +310 -0
  18. data/lib/fog/joyent/compute.rb +272 -0
  19. data/lib/fog/joyent/core.rb +10 -0
  20. data/lib/fog/joyent/errors.rb +91 -0
  21. data/lib/fog/joyent/models/analytics/field.rb +13 -0
  22. data/lib/fog/joyent/models/analytics/fields.rb +24 -0
  23. data/lib/fog/joyent/models/analytics/instrumentation.rb +82 -0
  24. data/lib/fog/joyent/models/analytics/instrumentations.rb +23 -0
  25. data/lib/fog/joyent/models/analytics/joyent_module.rb +13 -0
  26. data/lib/fog/joyent/models/analytics/joyent_modules.rb +24 -0
  27. data/lib/fog/joyent/models/analytics/metric.rb +17 -0
  28. data/lib/fog/joyent/models/analytics/metrics.rb +16 -0
  29. data/lib/fog/joyent/models/analytics/transformation.rb +13 -0
  30. data/lib/fog/joyent/models/analytics/transformations.rb +24 -0
  31. data/lib/fog/joyent/models/analytics/type.rb +16 -0
  32. data/lib/fog/joyent/models/analytics/types.rb +24 -0
  33. data/lib/fog/joyent/models/analytics/value.rb +20 -0
  34. data/lib/fog/joyent/models/compute/datacenter.rb +11 -0
  35. data/lib/fog/joyent/models/compute/datacenters.rb +21 -0
  36. data/lib/fog/joyent/models/compute/flavor.rb +19 -0
  37. data/lib/fog/joyent/models/compute/flavors.rb +21 -0
  38. data/lib/fog/joyent/models/compute/image.rb +26 -0
  39. data/lib/fog/joyent/models/compute/images.rb +30 -0
  40. data/lib/fog/joyent/models/compute/key.rb +19 -0
  41. data/lib/fog/joyent/models/compute/keys.rb +32 -0
  42. data/lib/fog/joyent/models/compute/network.rb +12 -0
  43. data/lib/fog/joyent/models/compute/networks.rb +14 -0
  44. data/lib/fog/joyent/models/compute/server.rb +124 -0
  45. data/lib/fog/joyent/models/compute/servers.rb +35 -0
  46. data/lib/fog/joyent/models/compute/snapshot.rb +44 -0
  47. data/lib/fog/joyent/models/compute/snapshots.rb +35 -0
  48. data/lib/fog/joyent/requests/analytics/create_instrumentation.rb +25 -0
  49. data/lib/fog/joyent/requests/analytics/delete_instrumentation.rb +23 -0
  50. data/lib/fog/joyent/requests/analytics/describe_analytics.rb +26 -0
  51. data/lib/fog/joyent/requests/analytics/get_instrumentation.rb +26 -0
  52. data/lib/fog/joyent/requests/analytics/get_instrumentation_value.rb +30 -0
  53. data/lib/fog/joyent/requests/analytics/list_instrumentations.rb +25 -0
  54. data/lib/fog/joyent/requests/compute/add_machine_tags.rb +19 -0
  55. data/lib/fog/joyent/requests/compute/create_key.rb +54 -0
  56. data/lib/fog/joyent/requests/compute/create_machine.rb +16 -0
  57. data/lib/fog/joyent/requests/compute/create_machine_snapshot.rb +16 -0
  58. data/lib/fog/joyent/requests/compute/delete_all_machine_metadata.rb +16 -0
  59. data/lib/fog/joyent/requests/compute/delete_all_machine_tags.rb +15 -0
  60. data/lib/fog/joyent/requests/compute/delete_key.rb +27 -0
  61. data/lib/fog/joyent/requests/compute/delete_machine.rb +15 -0
  62. data/lib/fog/joyent/requests/compute/delete_machine_metadata.rb +16 -0
  63. data/lib/fog/joyent/requests/compute/delete_machine_snapshot.rb +18 -0
  64. data/lib/fog/joyent/requests/compute/delete_machine_tag.rb +15 -0
  65. data/lib/fog/joyent/requests/compute/get_dataset.rb +27 -0
  66. data/lib/fog/joyent/requests/compute/get_image.rb +28 -0
  67. data/lib/fog/joyent/requests/compute/get_key.rb +29 -0
  68. data/lib/fog/joyent/requests/compute/get_machine.rb +29 -0
  69. data/lib/fog/joyent/requests/compute/get_machine_metadata.rb +24 -0
  70. data/lib/fog/joyent/requests/compute/get_machine_snapshot.rb +15 -0
  71. data/lib/fog/joyent/requests/compute/get_machine_tag.rb +18 -0
  72. data/lib/fog/joyent/requests/compute/get_package.rb +32 -0
  73. data/lib/fog/joyent/requests/compute/list_datacenters.rb +16 -0
  74. data/lib/fog/joyent/requests/compute/list_datasets.rb +24 -0
  75. data/lib/fog/joyent/requests/compute/list_images.rb +25 -0
  76. data/lib/fog/joyent/requests/compute/list_keys.rb +25 -0
  77. data/lib/fog/joyent/requests/compute/list_machine_snapshots.rb +15 -0
  78. data/lib/fog/joyent/requests/compute/list_machine_tags.rb +20 -0
  79. data/lib/fog/joyent/requests/compute/list_machines.rb +26 -0
  80. data/lib/fog/joyent/requests/compute/list_networks.rb +26 -0
  81. data/lib/fog/joyent/requests/compute/list_packages.rb +34 -0
  82. data/lib/fog/joyent/requests/compute/reboot_machine.rb +15 -0
  83. data/lib/fog/joyent/requests/compute/resize_machine.rb +16 -0
  84. data/lib/fog/joyent/requests/compute/start_machine.rb +16 -0
  85. data/lib/fog/joyent/requests/compute/start_machine_from_snapshot.rb +15 -0
  86. data/lib/fog/joyent/requests/compute/stop_machine.rb +16 -0
  87. data/lib/fog/joyent/requests/compute/update_machine_metadata.rb +15 -0
  88. data/lib/fog/joyent/version.rb +5 -0
  89. data/tests/helper.rb +18 -0
  90. data/tests/helpers/mock_helper.rb +16 -0
  91. data/tests/helpers/succeeds_helper.rb +9 -0
  92. data/tests/joyent/models/analytics/field_tests.rb +10 -0
  93. data/tests/joyent/models/analytics/fields_tests.rb +13 -0
  94. data/tests/joyent/models/analytics/instrumentation_tests.rb +13 -0
  95. data/tests/joyent/models/analytics/instrumentations_tests.rb +3 -0
  96. data/tests/joyent/models/analytics/joyent_module_tests.rb +10 -0
  97. data/tests/joyent/models/analytics/joyent_modules_tests.rb +13 -0
  98. data/tests/joyent/models/analytics/metric_tests.rb +10 -0
  99. data/tests/joyent/models/analytics/metrics_tests.rb +20 -0
  100. data/tests/joyent/models/analytics/transformation_tests.rb +10 -0
  101. data/tests/joyent/models/analytics/transformations_tests.rb +13 -0
  102. data/tests/joyent/models/analytics/type_tests.rb +10 -0
  103. data/tests/joyent/models/analytics/types_tests.rb +13 -0
  104. data/tests/joyent/requests/analytics/instrumentation_tests.rb +44 -0
  105. data/tests/joyent/requests/compute/datasets_tests.rb +58 -0
  106. data/tests/joyent/requests/compute/keys_tests.rb +47 -0
  107. data/tests/joyent/requests/compute/machines_tests.rb +66 -0
  108. data/tests/joyent/requests/compute/networks_tests.rb +39 -0
  109. data/tests/joyent/requests/compute/packages_tests.rb +68 -0
  110. metadata +235 -0
@@ -0,0 +1,26 @@
1
+ module Fog
2
+ module Compute
3
+ class Joyent
4
+ class Mock
5
+ def list_networks(options={})
6
+ res = Excon::Response.new
7
+ res.status = 200
8
+ res.body = self.data[:networks].values
9
+ res
10
+ end
11
+ end
12
+
13
+ class Real
14
+ def list_networks(options={})
15
+ request(
16
+ :path => "/my/networks",
17
+ :method => "GET",
18
+ :query => options,
19
+ :expects => 200,
20
+ :idempotent => true
21
+ )
22
+ end
23
+ end
24
+ end
25
+ end
26
+ end
@@ -0,0 +1,34 @@
1
+ module Fog
2
+ module Compute
3
+ class Joyent
4
+ class Mock
5
+ def list_packages
6
+ response = Excon::Response.new()
7
+ response.status = 200
8
+ response.body = self.data[:packages].values
9
+ response
10
+ end
11
+ end
12
+
13
+ class Real
14
+ # Lists all the packages available to the authenticated user
15
+ # ==== Returns
16
+ # Exon::Response<Array>
17
+ # * name<~String> The "friendly name for this package
18
+ # * memory<~Number> How much memory will by available (in Mb)
19
+ # * disk<~Number> How much disk space will be available (in Gb)
20
+ # * swap<~Number> How much swap memory will be available (in Mb)
21
+ # * default<~Boolean> Whether this is the default package in this datacenter"
22
+ #
23
+ def list_packages
24
+ request(
25
+ :path => "/my/packages",
26
+ :method => "GET",
27
+ :expects => 200,
28
+ :idempotent => true
29
+ )
30
+ end
31
+ end # Real
32
+ end
33
+ end
34
+ end
@@ -0,0 +1,15 @@
1
+ module Fog
2
+ module Compute
3
+ class Joyent
4
+ class Real
5
+ def reboot_machine(id)
6
+ request(
7
+ :method => "POST",
8
+ :query => {"action" => "reboot"},
9
+ :path => "/my/machines/#{id}"
10
+ )
11
+ end
12
+ end
13
+ end
14
+ end
15
+ end
@@ -0,0 +1,16 @@
1
+ module Fog
2
+ module Compute
3
+ class Joyent
4
+ class Real
5
+ def resize_machine(id, package)
6
+ request(
7
+ :method => "POST",
8
+ :path => "/my/machines/#{id}",
9
+ :query => {"action" => "resize", "package" => package},
10
+ :expects => [202]
11
+ )
12
+ end
13
+ end
14
+ end
15
+ end
16
+ end
@@ -0,0 +1,16 @@
1
+ module Fog
2
+ module Compute
3
+ class Joyent
4
+ class Real
5
+ def start_machine(id)
6
+ request(
7
+ :method => "POST",
8
+ :path => "/my/machines/#{id}",
9
+ :query => {"action" => "start"},
10
+ :expects => 202
11
+ )
12
+ end
13
+ end
14
+ end
15
+ end
16
+ end
@@ -0,0 +1,15 @@
1
+ module Fog
2
+ module Compute
3
+ class Joyent
4
+ class Real
5
+ def start_machine_from_snapshot(machine_id, snapshot_name)
6
+ request(
7
+ :method => "POST",
8
+ :path => "/my/machines/#{machine_id}/snapshots/#{snapshot_name}",
9
+ :expects => 202
10
+ )
11
+ end
12
+ end
13
+ end
14
+ end
15
+ end
@@ -0,0 +1,16 @@
1
+ module Fog
2
+ module Compute
3
+ class Joyent
4
+ class Real
5
+ def stop_machine(uuid)
6
+ request(
7
+ :method => "POST",
8
+ :path => "/my/machines/#{uuid}",
9
+ :query => {"action" => "stop"},
10
+ :expects => 202
11
+ )
12
+ end
13
+ end
14
+ end
15
+ end
16
+ end
@@ -0,0 +1,15 @@
1
+ module Fog
2
+ module Compute
3
+ class Joyent
4
+ class Real
5
+ def update_machine_metadata(machine_id, metadata)
6
+ request(
7
+ :method => "POST",
8
+ :path => "/my/machines/#{machine_id}/metadata",
9
+ :body => metadata
10
+ )
11
+ end
12
+ end
13
+ end
14
+ end
15
+ end
@@ -0,0 +1,5 @@
1
+ module Fog
2
+ module Joyent
3
+ VERSION = "0.0.1"
4
+ end
5
+ end
@@ -0,0 +1,18 @@
1
+ ENV['FOG_RC'] = ENV['FOG_RC'] || File.expand_path('../.fog', __FILE__)
2
+ ENV['FOG_CREDENTIAL'] = ENV['FOG_CREDENTIAL'] || 'default'
3
+
4
+ require 'fog/joyent'
5
+
6
+ Excon.defaults.merge!(:debug_request => true, :debug_response => true)
7
+
8
+ require File.expand_path(File.join(File.dirname(__FILE__), 'helpers', 'mock_helper'))
9
+
10
+ # This overrides the default 600 seconds timeout during live test runs
11
+ if Fog.mocking?
12
+ FOG_TESTING_TIMEOUT = ENV['FOG_TEST_TIMEOUT'] || 2000
13
+ Fog.timeout = 2000
14
+ Fog::Logger.warning "Setting default fog timeout to #{Fog.timeout} seconds"
15
+ Thread.current[:tags] << '-joyent'
16
+ else
17
+ FOG_TESTING_TIMEOUT = Fog.timeout
18
+ end
@@ -0,0 +1,16 @@
1
+ # Use so you can run in mock mode from the command line
2
+ #
3
+ # FOG_MOCK=true fog
4
+
5
+ if ENV["FOG_MOCK"] == "true"
6
+ Fog.mock!
7
+ end
8
+
9
+ # if in mocked mode, fill in some fake credentials for us
10
+ if Fog.mock?
11
+ Fog.credentials = {
12
+ :joyent_username => "joyentuser",
13
+ :joyent_keyfile => "~/.ssh/id_rsa",
14
+ :joyent_keyname => "joyentuser"
15
+ }.merge(Fog.credentials)
16
+ end
@@ -0,0 +1,9 @@
1
+ module Shindo
2
+ class Tests
3
+ def succeeds
4
+ test('succeeds') do
5
+ !!instance_eval(&Proc.new)
6
+ end
7
+ end
8
+ end
9
+ end
@@ -0,0 +1,10 @@
1
+ Shindo.tests("Fog::Joyent[:analytics] | field", ['joyent']) do
2
+ @analytics = Fog::Joyent[:analytics]
3
+ @field = @analytics.fields.first
4
+
5
+ tests('read only') do
6
+ returns(false, 'should not save') { @field.respond_to?(:save)}
7
+ returns(false, 'should not allow creating a new one') { @field.respond_to?(:create)}
8
+ returns(false, 'should not allow destroying') { @field.respond_to?(:destroy)}
9
+ end
10
+ end
@@ -0,0 +1,13 @@
1
+ Shindo.tests("Fog::Joyent[:analytics] | fields", %w{joyent}) do
2
+ @analytics = Fog::Joyent[:analytics]
3
+ @fields = @analytics.fields
4
+
5
+ tests('#all').succeeds do
6
+ @fields.all
7
+ end
8
+
9
+ tests('#new').succeeds do
10
+ @fields.new(['apache', { 'label' => 'Apache', 'type' => 'string' }])
11
+ end
12
+
13
+ end
@@ -0,0 +1,13 @@
1
+ Shindo.tests("Fog::Joyent[:analytics] | instrumentation", %w{joyent }) do
2
+ model_tests(Fog::Joyent[:analytics].instrumentations, {:joyent_module => 'cpu', :stat => 'usage'}, true)
3
+
4
+ @analytics = Fog::Joyent[:analytics]
5
+ @instrumentation = @analytics.instrumentations.first
6
+
7
+ tests('#values') do
8
+ @values = @instrumentation.values(Time.now.utc.to_i - 600, 5)
9
+
10
+ returns(Array) { @values.class }
11
+ returns(Fog::Joyent::Analytics::Value) { @values.first.class }
12
+ end
13
+ end
@@ -0,0 +1,3 @@
1
+ Shindo.tests("Fog::Joyent[:analytics] | instrumentations", %w{joyent}) do
2
+ collection_tests(Fog::Joyent[:analytics].instrumentations, {:joyent_module => 'cpu', :stat => 'usage'}, true)
3
+ end
@@ -0,0 +1,10 @@
1
+ Shindo.tests("Fog::Joyent[:analytics] | joyent_module", %w{joyent}) do
2
+ @analytics = Fog::Joyent[:analytics]
3
+ @joyent_module = @analytics.joyent_modules.first
4
+
5
+ tests('read only') do
6
+ returns(false, 'should not save') { @joyent_module.respond_to?(:save)}
7
+ returns(false, 'should not allow creating a new one') { @joyent_module.respond_to?(:create)}
8
+ returns(false, 'should not allow destroying') { @joyent_module.respond_to?(:destroy)}
9
+ end
10
+ end
@@ -0,0 +1,13 @@
1
+ Shindo.tests("Fog::Joyent[:analytics] | joyent_modules", %w{joyent}) do
2
+ @analytics = Fog::Joyent[:analytics]
3
+ @joyent_modules = @analytics.joyent_modules
4
+
5
+ tests('#all').succeeds do
6
+ @joyent_modules.all
7
+ end
8
+
9
+ tests('#new').succeeds do
10
+ @joyent_modules.new(['cpu', { 'label' => 'CPU' }])
11
+ end
12
+
13
+ end
@@ -0,0 +1,10 @@
1
+ Shindo.tests("Fog::Joyent[:analytics] | metric", %w{joyent}) do
2
+ @analytics = Fog::Joyent[:analytics]
3
+ @metric = @analytics.metrics.first
4
+
5
+ tests('read only') do
6
+ returns(false, 'should not save') { @metric.respond_to?(:save)}
7
+ returns(false, 'should not allow creating a new one') { @metric.respond_to?(:create)}
8
+ returns(false, 'should not allow destroying') { @metric.respond_to?(:destroy)}
9
+ end
10
+ end
@@ -0,0 +1,20 @@
1
+ Shindo.tests("Fog::Joyent[:analytics] | metrics", %w{joyent}) do
2
+ @analytics = Fog::Joyent[:analytics]
3
+ @metrics = @analytics.metrics
4
+
5
+ tests('#all').succeeds do
6
+ @metrics.all
7
+ end
8
+
9
+ tests('#new').succeeds do
10
+ @metrics.new({
11
+ "module" => "cpu",
12
+ "stat" => "thread_executions",
13
+ "label" => "thread executions",
14
+ "interval" => "interval",
15
+ "fields" => ["hostname", "zonename", "runtime"],
16
+ "unit" => "operations"
17
+ })
18
+ end
19
+
20
+ end
@@ -0,0 +1,10 @@
1
+ Shindo.tests("Fog::Joyent[:analytics] | transformation", %w{joyent}) do
2
+ @analytics = Fog::Joyent[:analytics]
3
+ @transformation = @analytics.transformations.first
4
+
5
+ tests('read only') do
6
+ returns(false, 'should not save') { @transformation.respond_to?(:save)}
7
+ returns(false, 'should not allow creating a new one') { @transformation.respond_to?(:create)}
8
+ returns(false, 'should not allow destroying') { @transformation.respond_to?(:destroy)}
9
+ end
10
+ end
@@ -0,0 +1,13 @@
1
+ Shindo.tests("Fog::Joyent[:analytics] | transformations", %w{joyent}) do
2
+ @analytics = Fog::Joyent[:analytics]
3
+ @transformations = @analytics.transformations
4
+
5
+ tests('#all').succeeds do
6
+ @transformations.all
7
+ end
8
+
9
+ tests('#new').succeeds do
10
+ @transformations.new(['geolocate', { 'label' => 'geolocate IP addresses', "fields" => ["raddr"] }])
11
+ end
12
+
13
+ end
@@ -0,0 +1,10 @@
1
+ Shindo.tests("Fog::Joyent[:analytics] | type", %w{joyent}) do
2
+ @analytics = Fog::Joyent[:analytics]
3
+ @type = @analytics.types.first
4
+
5
+ tests('read only') do
6
+ returns(false, 'should not save') { @type.respond_to?(:save)}
7
+ returns(false, 'should not allow creating a new one') { @type.respond_to?(:create)}
8
+ returns(false, 'should not allow destroying') { @type.respond_to?(:destroy)}
9
+ end
10
+ end
@@ -0,0 +1,13 @@
1
+ Shindo.tests("Fog::Joyent[:analytics] | types", %w{joyent}) do
2
+ @analytics = Fog::Joyent[:analytics]
3
+ @types = @analytics.types
4
+
5
+ tests('#all').succeeds do
6
+ @types.all
7
+ end
8
+
9
+ tests('#new').succeeds do
10
+ @types.new(['string', {'arity' => 'discrete', 'unit' => ''}])
11
+ end
12
+
13
+ end
@@ -0,0 +1,44 @@
1
+ Shindo.tests("Fog::Compute[:joyent] | instrumentation requests", ['joyent']) do
2
+
3
+ @analytics = Fog::Compute[:joyent]
4
+
5
+ @instrumentation_schema = {
6
+ 'id' => String,
7
+ 'module' => String,
8
+ 'stat' => String,
9
+ 'predicate' => Hash,
10
+ 'decomposition' => [String],
11
+ 'value-dimension' => Integer,
12
+ 'value-arity' => String,
13
+ 'retention-time' => Integer,
14
+ 'granularity' => Integer,
15
+ 'idle-max' => Integer,
16
+ 'transformations' => [String],
17
+ 'persist-data' => Fog::Boolean,
18
+ 'crtime' => Integer,
19
+ 'value-scope' => String,
20
+ 'uris' => [
21
+ {
22
+ 'uri' => String,
23
+ 'name' => String
24
+ }
25
+ ]
26
+ }
27
+
28
+ tests('#create_instrumentation').data_matches_schema(@instrumentation_schema) do
29
+ @analytics.create_instrumentation.body
30
+ end
31
+
32
+ tests('#list_instrumentations') do
33
+ data_matches_schema(@instrumentation_schema) do
34
+ @analytics.list_instrumentations.body.first
35
+ end
36
+
37
+ returns(Array) { @analytics.list_instrumentations.body.class }
38
+ end
39
+
40
+ tests('#delete_instrumentation') do
41
+ returns(204) { @analytics.delete_instrumentation(Fog::Joyent::Analytics::Mock.data[:instrumentation]['id']).status }
42
+ end
43
+
44
+ end
@@ -0,0 +1,58 @@
1
+ Shindo.tests("Fog::Compute[:joyent] | dataset requests", ["joyent"]) do
2
+ @dataset_format = {
3
+ "description" => String,
4
+ "requirements" => {
5
+ "max_memory" => Integer,
6
+ "min_memory" => Integer
7
+ },
8
+ "name" => String,
9
+ "version" => String,
10
+ "os" => String,
11
+ "id" => String,
12
+ "urn" => String,
13
+ "default" => Fog::Boolean,
14
+ "type" => String,
15
+ "created" => Time,
16
+ }
17
+
18
+ if Fog.mock?
19
+ Fog::Compute[:joyent].data[:datasets] = {
20
+ "33904834-1f01-49d3-bed3-b642e158c375" => {
21
+ "id" => "33904834-1f01-49d3-bed3-b642e158c375",
22
+ "urn" => "sdc:sdc:zeus-simple-lb-200mbps:1.1.1",
23
+ "name" => "zeus-simple-lb-200mbps",
24
+ "os" => "smartos",
25
+ "type" => "smartmachine",
26
+ "description" => "Zeus Simple Load Balancer 200 Mbps SmartMachine",
27
+ "default" => false,
28
+ "requirements" => {
29
+ "max_memory" => 32768,
30
+ "min_memory" => 4096
31
+ },
32
+ "version" => "1.1.1",
33
+ "created" => Time.parse("2011-09-15T07:39:13+00:00")
34
+ },
35
+ "3fcf35d2-dd79-11e0-bdcd-b3c7ac8aeea6" => {
36
+ "id" => "3fcf35d2-dd79-11e0-bdcd-b3c7ac8aeea6",
37
+ "urn" => "sdc:sdc:mysql:1.4.1",
38
+ "name" => "mysql",
39
+ "os" => "smartos",
40
+ "type" => "smartmachine",
41
+ "description" => "MySQL SmartMachine",
42
+ "default" => false,
43
+ "requirements" => {
44
+ "max_memory" => 32768,
45
+ "min_memory" => 4096
46
+ },
47
+ "version" => "1.4.1",
48
+ "created" => Time.parse("2011-09-15T05:01:34+00:00")
49
+ }
50
+ }
51
+ end
52
+
53
+ tests("#list_datasets") do
54
+ formats(@dataset_format) do
55
+ Fog::Compute[:joyent].list_datasets.body.first
56
+ end
57
+ end
58
+ end