Sha256: c66c822f2cac330c674b48860997543bccaf6dd8ec98d37766fd6f0cd185a358

Contents?: true

Size: 1.2 KB

Versions: 34

Compression:

Stored size: 1.2 KB

Contents

Shindo.tests("Fog::Joyent[:analytics] | instrumentation requests", %w{joyent}) do

  @analytics = Fog::Joyent[:analytics]

  @instrumentation_schema = {
      'id' => String,
      'module' => String,
      'stat' => String,
      'predicate' => Hash,
      'decomposition' => [String],
      'value-dimension' => Integer,
      'value-arity' => String,
      'retention-time' => Integer,
      'granularity' => Integer,
      'idle-max' => Integer,
      'transformations' => [String],
      'persist-data' => Fog::Boolean,
      'crtime' => Integer,
      'value-scope' => String,
      'uris' => [
          {
              'uri' => String,
              'name' => String
          }
      ]
  }

  tests('#create_instrumentation').data_matches_schema(@instrumentation_schema) do
    @analytics.create_instrumentation.body
  end

  tests('#list_instrumentations') do
    data_matches_schema(@instrumentation_schema) do
      @analytics.list_instrumentations.body.first
    end

    returns(Array) { @analytics.list_instrumentations.body.class }
  end

  tests('#delete_instrumentation') do
    returns(204) { @analytics.delete_instrumentation(Fog::Joyent::Analytics::Mock.data[:instrumentation]['id']).status }
  end

end

Version data entries

34 entries across 34 versions & 4 rubygems

Version Path
fog-1.40.0 tests/joyent/requests/analytics/instrumentation_tests.rb
fog-1.39.0 tests/joyent/requests/analytics/instrumentation_tests.rb
fog-1.38.0 tests/joyent/requests/analytics/instrumentation_tests.rb
fog-1.37.0 tests/joyent/requests/analytics/instrumentation_tests.rb
fog-1.36.0 tests/joyent/requests/analytics/instrumentation_tests.rb
fog-1.35.0 tests/joyent/requests/analytics/instrumentation_tests.rb
fog-2.0.0.pre.0 tests/joyent/requests/analytics/instrumentation_tests.rb
vagrant-cloudstack-1.2.0 vendor/bundle/gems/fog-1.32.0/tests/joyent/requests/analytics/instrumentation_tests.rb
fog-1.34.0 tests/joyent/requests/analytics/instrumentation_tests.rb
fog-1.33.0 tests/joyent/requests/analytics/instrumentation_tests.rb
fog-1.32.0 tests/joyent/requests/analytics/instrumentation_tests.rb
fog-1.31.0 tests/joyent/requests/analytics/instrumentation_tests.rb
vagrant-cloudstack-1.1.0 vendor/bundle/gems/fog-1.22.1/tests/joyent/requests/analytics/instrumentation_tests.rb
fog-1.30.0 tests/joyent/requests/analytics/instrumentation_tests.rb
fog-1.29.0 tests/joyent/requests/analytics/instrumentation_tests.rb
fog-1.28.0 tests/joyent/requests/analytics/instrumentation_tests.rb
fog-1.27.0 tests/joyent/requests/analytics/instrumentation_tests.rb
fog-1.26.0 tests/joyent/requests/analytics/instrumentation_tests.rb
fog-1.25.0 tests/joyent/requests/analytics/instrumentation_tests.rb
nsidc-fog-1.24.1 tests/joyent/requests/analytics/instrumentation_tests.rb