Sha256: 47b54278c2565b474d5a84e8aaac79fd16b32912c2d0f6c90a7d51f3b199fb35

Contents?: true

Size: 489 Bytes

Versions: 17

Compression:

Stored size: 489 Bytes

Contents

require File.expand_path(File.dirname(__FILE__) + '/spec_helper')

describe Gritano::Key do
  it 'should have a name' do
    key = Gritano::Key.new(key: "key")
    key.should be_invalid
  end

  it 'should have a key' do
    key = Gritano::Key.new(name: "name")
    key.should be_invalid
  end

  it 'should generate authorized_keys file' do
    Gritano::User.create(login: 'login').keys.create(key: "key", name: "name")
    Gritano::Key.authorized_keys.should match /^command=/
  end
end

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
gritano-0.5.3 spec/model_key_spec.rb
gritano-0.5.2 spec/model_key_spec.rb
gritano-0.5.1 spec/model_key_spec.rb
gritano-0.5.0 spec/model_key_spec.rb
gritano-0.4.1 spec/model_key_spec.rb
gritano-0.4.0 spec/model_key_spec.rb
gritano-0.3.2 spec/model_key_spec.rb
gritano-0.3.0 spec/model_key_spec.rb
gritano-0.2.2 spec/model_key_spec.rb
gritano-0.2.1 spec/model_key_spec.rb
gritano-0.2.0 spec/model_key_spec.rb
gritano-0.1.7 spec/model_key_spec.rb
gritano-0.1.6 spec/model_key_spec.rb
gritano-0.1.5 spec/model_key_spec.rb
gritano-0.1.4 spec/model_key_spec.rb
gritano-0.1.3 spec/model_key_spec.rb
gritano-0.1.2 spec/model_key_spec.rb