removed the encryption key= method, and user with private key factory

This commit is contained in:
ilya 2010-09-27 10:10:54 -07:00
parent 9ff3263444
commit 98bc2df841
2 changed files with 0 additions and 10 deletions

View file

@ -291,10 +291,4 @@ class User
OpenSSL::PKey::RSA.new( serialized_private_key ) OpenSSL::PKey::RSA.new( serialized_private_key )
end end
def encryption_key= new_key
raise TypeError unless new_key.class == OpenSSL::PKey::RSA
serialized_private_key = new_key.export
end
end end

View file

@ -25,10 +25,6 @@ Factory.define :album do |p|
p.person { |a| Factory.create(:person) } p.person { |a| Factory.create(:person) }
end end
Factory.define :person_with_private_key, :parent => :person do |p|
p.serialized_key OpenSSL::PKey::RSA.generate(1024).export
end
Factory.define :user do |u| Factory.define :user do |u|
u.sequence(:username) {|n| "bob#{n}"} u.sequence(:username) {|n| "bob#{n}"}
u.sequence(:email) {|n| "bob#{n}@pivotallabs.com"} u.sequence(:email) {|n| "bob#{n}@pivotallabs.com"}