Sha256: a5f3e6ba89370e112b2d55131a1d97c14dab83823df1ecf45a81e2bb34450819

Contents?: true

Size: 637 Bytes

Versions: 1

Compression:

Stored size: 637 Bytes

Contents

require 'spec_helper'

describe "Smartdc::Api::Keys" do
  before(:all) do
    @key = fixture('key')
  end

  describe ".create" do
    it "should return a key" do
      key = client.keys.create @key
      key.name.should eq @key['name']
    end
  end

  describe ".read" do
    it "should return a key" do
      client.keys(@key['name']).read.name.should eq @key['name']
    end
  end

  describe ".find" do
    it "should return some keys" do
      client.keys.find.count.should > 0
    end
  end

  describe ".delete" do
    it "should return true when success" do
      client.keys(@key['name']).delete.should be_nil
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
smartdc-0.4.0 spec/smartdc/api/keys_spec.rb