Sha256: 2da055abed66e646debaa96015db0a91c615d04e38553e3bd8502a52528687dc

Contents?: true

Size: 955 Bytes

Versions: 13

Compression:

Stored size: 955 Bytes

Contents

Shindo.tests('Fog::Identity[:openstack] | user requests', ['openstack']) do

  @user_format = {
    'id'   => String,
    'name' => String,
    'enabled'  => Fog::Boolean,
    'email'    => String,
    'tenantId' => Fog::Nullable::String
  }

  tests('success') do
    tests('#create_user("Onamae", "spoof", "user@email.com", "t3n4nt1d", true)').formats(@user_format, false) do
      @user = Fog::Identity[:openstack].create_user("Onamae", "spoof", "morph@example.com", "m0rPh1d").body['user']
    end

    tests('#list_users').formats({'users' => [@user_format]}) do
      Fog::Identity[:openstack].list_users.body
    end

    tests("#update_user(#{@user['id']}, :name => 'fogupdateduser')").succeeds do
      Fog::Identity[:openstack].update_user(@user['id'], :name => 'fogupdateduser', :email => 'fog@test.com')
    end

    tests("#delete_user(#{@user['id']})").succeeds do
      Fog::Identity[:openstack].delete_user(@user['id'])
    end

  end
end

Version data entries

13 entries across 13 versions & 7 rubygems

Version Path
fog-nirvanix-1.8.2 tests/openstack/requests/identity/user_tests.rb
fog-nirvanix-1.8.1 tests/openstack/requests/identity/user_tests.rb
fog-parser-fix-1.6.1 tests/openstack/requests/identity/user_tests.rb
fog-test-again-1.6.0 tests/openstack/requests/identity/user_tests.rb
fog-parser-fix-1.6.0 tests/openstack/requests/identity/user_tests.rb
fog-sgonyea-1.8.1 tests/openstack/requests/identity/user_tests.rb
fog-1.8.0 tests/openstack/requests/identity/user_tests.rb
fog-maestrodev-1.7.0.20121114190951 tests/openstack/requests/identity/user_tests.rb
fog-1.7.0 tests/openstack/requests/identity/user_tests.rb
fog-1.6.0 tests/openstack/requests/identity/user_tests.rb
fog-1.5.0 tests/openstack/requests/identity/user_tests.rb
rackspace-fog-1.4.2 tests/openstack/requests/identity/user_tests.rb
fog-1.4.0 tests/openstack/requests/identity/user_tests.rb