Sha256: 52ab794802cca479f3cfa73a7e73933a1f817ef89f91bfa4a19d96da2e6dd8e8

Contents?: true

Size: 1.22 KB

Versions: 39

Compression:

Stored size: 1.22 KB

Contents

require 'spec_helper'

describe "as a user" do
  let(:client)       { create_client }
  let!(:account)     { create_account(client: client) }
  let!(:provider)    { create_provider(account: account) }
  let!(:environment) { create_environment(account: account, name: Faker::Name.first_name) }
  let!(:keypair)     { client.keypairs.create(name: SecureRandom.hex(6), public_key: SSHKey.generate.ssh_public_key) }

  it "creates a keypair deployment" do
    keypair_deployment = client.keypair_deployments.create(keypair: keypair, environment: environment)

    expect(keypair_deployment.identity).not_to be_nil
    expect(keypair_deployment.keypair).to eq(keypair)
    expect(keypair_deployment.environment).to eq(environment)
  end

  context "with a keypair deployment" do
    let!(:keypair_deployment) { client.keypair_deployments.create(keypair: keypair, environment: environment) }

    it "lists the keypair deployment" do
      expect(client.keypair_deployments.all).to include(keypair_deployment)
    end

    it "lists an environment's keypairs" do
      expect(environment.keypairs.all.to_a).to eq([keypair])
    end

    it "lists a keypair's deployments"
    it "searches keypairs by name"
    it "searches keypairs by fingerprint"
  end
end

Version data entries

39 entries across 39 versions & 2 rubygems

Version Path
ey-core-3.6.0.autoscaling1 spec/keypair_deployments_spec.rb
ey-core-3.6.4 spec/keypair_deployments_spec.rb
ey-core-3.6.3 spec/keypair_deployments_spec.rb
ey-core-3.6.1 spec/keypair_deployments_spec.rb
groove-ey-core-3.6.3 spec/keypair_deployments_spec.rb
groove-ey-core-3.6.2 spec/keypair_deployments_spec.rb
groove-ey-core-3.6.1 spec/keypair_deployments_spec.rb
ey-core-3.5.0 spec/keypair_deployments_spec.rb
ey-core-3.4.4 spec/keypair_deployments_spec.rb
ey-core-3.4.2 spec/keypair_deployments_spec.rb
ey-core-3.4.1 spec/keypair_deployments_spec.rb
ey-core-3.4.0 spec/keypair_deployments_spec.rb
ey-core-3.3.1 spec/keypair_deployments_spec.rb
ey-core-3.3.0 spec/keypair_deployments_spec.rb
ey-core-3.2.6 spec/keypair_deployments_spec.rb
ey-core-3.2.5 spec/keypair_deployments_spec.rb
ey-core-3.2.4 spec/keypair_deployments_spec.rb
ey-core-3.2.3 spec/keypair_deployments_spec.rb
ey-core-3.2.2 spec/keypair_deployments_spec.rb
ey-core-3.2.1 spec/keypair_deployments_spec.rb